Is there any dotnet function that will convert an object of type
System.DataType to a IDataParameter.DbType enumeration?
When I read off a table schema (IDataReader.GetSchemaTable) the data types
for each column in the table are returned as System.DataType.
I would like to write a function to create IDbDataParameters for sql queries
generically according to the type stored in the table schema.
or am i missing something in GetSchemaTable that's already storing the
DbType and so I dont have to do the conversion.
thanks