Extension method on SQLDataReader to check Null Bytes

Niladri.Biswas
Posted by Niladri.Biswas under C# category on | Points: 40 | Views : 846
public static byte CheckNullByte(this SqlDataReader dr, int ordinal)
{
return dr.IsDBNull(ordinal) ? byte.MinValue : dr.GetByte(ordinal);
}

Comments or Responses

Login to post response