get database native column format

  • Thread starter Thread starter metalseb
  • Start date Start date
M

metalseb

Hi there.

I need to retrieve the native database data format of a specified column,
afetr populating a dataset.

Example : Column 1 is "Name", format given by DataColumn.DataType is
System.String. MySQL native format for this column is VARCHAR. Is there a
way to get this automatically or do I have to build a correspondance table
for each database engine ?

Thanxxx !
 
Hi,

One way is to use OleDbConnection.GetOleDbSchemaTable method.
Other than that you'll have to use native database stuff (depends on the
database of course).
 
Back
Top