Ok, here's the results of my test SqlDataReader vs. SQLiteDataReader (1.0.31.0)
Using the statement:
SELECT 'foo', 'bar', 1
UNION
SELECT NULL, '', NULL
SQLite and SqlClient behaved identically, except for the fact that SQLite actually returned the data in reverse order (the row with NULL,'', NULL came first)
while (reader.Read())
{
Console.WriteLine(reader.GetValue(0).GetType().ToString());
}
SqlClient Output:
System.String
System.DbNull
SQLite Output (reverse order, but same result):
System.DbNull
System.String
Both engines threw an exception when calling GetString(0) on the NULL row.
So I'm afraid this is the way its going to stay. Any difference in behavior of the provider at this level could make for larger issues later on with all the technologies built on top of these core functions.
Robert