#23 SQLiteCommandBuilder and ColumnMappings

open
nobody
None
5
2005-01-31
2005-01-31
Anonymous
No

Hi there,

If I use the commandbuilder to generate my
dataadapter's commands after mapping the dataset
columns to different columns in the database, I get the
following error on the update call:

{System.ArgumentException}
[System.ArgumentException]:
{System.ArgumentException}
InnerException: Nothing
Message: "Column '[DatabaseColumnName]' does not
belong to table [DatasetTableName]."

It turns out the dataparameter objects generated by the
commandbuilder set their sourcename property to the
database column names instead of the dataset column
names. And so, after the commands have been built, I
need to go through all the parameters and fix all their
source column names.

Thank you!

mbech@mdsi.ca

Discussion