J
James Autry
Does null check have to explicitly be performed on every nullable value from
a DataReader return. ie.
for:
DataReader dr = sqlCommand.ExecuteReader()
while( dr.Read()
{
int intTestValue = dr.GetInt32( dr.GetOrdinal("TestValue"));
}
This will cause an exception if value is null, so do I have to do a special
check for null on every return?? Or is there a more efficient way of doing
this?
Thanks
a DataReader return. ie.
for:
DataReader dr = sqlCommand.ExecuteReader()
while( dr.Read()
{
int intTestValue = dr.GetInt32( dr.GetOrdinal("TestValue"));
}
This will cause an exception if value is null, so do I have to do a special
check for null on every return?? Or is there a more efficient way of doing
this?
Thanks