Hmmm.... I think #2 makes more sense. If were my system, I would wrap the fact that you are updating multiple tables from a single row in a stored procedure. In that way, creating the DataAdapter's Command objects will be trivial (ok, Stored Procs are never trivial). That way you can update the database from the DataSet and you should never have to rebind to the DataGrid. Am I still missing the point?
Thanks, Shawn Wildermuth [EMAIL PROTECTED] > -----Original Message----- > From: dotnet discussion [mailto:[EMAIL PROTECTED]] > On Behalf Of Bob Edwards > Sent: Monday, April 15, 2002 4:12 PM > To: [EMAIL PROTECTED] > Subject: Re: [DOTNET] updating dataset and dataform > > > Thanks for the feedback but my question must not have been clear. > > I can update in one of two ways: > > 1. Update the database and then refill the dataset and then > rebind to the datagrid or, 2. Update the dataset, rebind the > datagrid and from the dataset update the db > > The datastructure is somewhat complex (two tables in the > dataset and each table draws from multiple tables in the db) > and every edit should be written back to the db. Do you > recommend 1 or 2? > > Thanks. > > > -----Original Message----- > > From: dotnet discussion > [mailto:[EMAIL PROTECTED]]On Behalf > > Of Shawn > Wildermuth > > Sent: Monday, April 15, 2002 3:56 PM > > To: [EMAIL PROTECTED] > > Subject: Re: [DOTNET] updating dataset and dataform > > > > > > The DataAdapter usually only updates a single Table at a > time. If you > > send a DataSet to the Update (as in > dataAdapter.Update(dataSet)), it > > will attempt to update a table called "Table". Probably > not what you > > want. > > > > > > > > You can read messages from the DOTNET archive, unsubscribe > from DOTNET, or subscribe to other DevelopMentor lists at > http://discuss.develop.com. > You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.