Repository navigation
Add the GetColumnSchema API to SqlDataReader - #6097
Conversation
| { | ||
| return _metaData.dbColumnSchema; | ||
| } | ||
| return null; |
There was a problem hiding this comment.
Should an empty collection be returned instead of null? It's not usually a good practice to return null from a collection member.
There was a problem hiding this comment.
Is zero-length ever possible as the "real" result, and if so is a consumer ever likely to care to distinguish that from not-available? (I can't think of how it might be zero-length, but maybe there's a way I'm not considering).
|
@justinvp Thanks for the review. I will take care of your comments. |
|
The tests are failing because of the new types exposed in System.Data.Common not being accessible via the packaged assemblies. |
| private CommandBehavior _commandBehavior; | ||
|
|
||
| private static int s_objectTypeCount; // Bid counter | ||
| private static ReadOnlyCollection<DbColumn> s_emptySchema = new ReadOnlyCollection<DbColumn>(new DbColumn[0]); |
|
LGTM |
|
@stephentoub the tests will fail. I am waiting for a nightly build of data common to be able to fix this. |
|
Ah, ok :) I saw lots of read and kicked it thinking it may have been due to all the outages yesterday. |
39e37dd to
e42ae02
Compare
|
@dotnet-bot test this please |
e42ae02 to
c88c3f1
Compare
|
@stephentoub This PR is stuck. I submitted an update last night and also sometime ago, however the build is not kicking in. Is there something I can do? Or should I create a new PR with these changes |
|
@stephentoub For some reason, the CI thinks that there are no changes in this PR. !! |
|
It's working now after I closed and reopened, right? |
|
Yes now I see progress in the CI. |
Add the GetColumnSchema API to SqlDataReader
Add the GetColumnSchema API to SqlDataReader Commit migrated from dotnet/corefx@d98dc1d
The change contains the implementation of IDbDolumnSchemaGenerator on SqlDataReader to get the columns as the API to retrieve the Columns metadata.
This change contains the reference to System.Data.Common via the Project Reference in csproj
Sending this PR out for Code Review and this will be complete with another commit to remove the Project Reference once System.Data.Common Nuget packages are updated.