I have a simple piece of code
bool retrievalAttempted = Convert.ToBoolean(reader.GetByte(1));
where column 1 is of type BIT NOT NULL and yet I keep getting the exception
System.InvalidCastException: Specified cast is not valid.
What am I doing wrong here?
bittype corresponds to a boolean, not a byte