How do I release a DataAdapter.

  • Thread starter Thread starter Manuel Canas
  • Start date Start date
M

Manuel Canas

Hi All,

After I call a data adapter for a straight insert on the DB, if I call the
same data adapter for an update on the same record, it throws an concurency
error saying that the update command updated 0 rows.

Now, how do I release and initialize it again so I can update that record
right after the insert command?

Thanks very much for you input on this one.

Manuel
 
Either don't use the DataAdapter for the straight insert or insert the new
data into a DataSet that was filled by the DataAdapter and then call the
DataAdapter's update method.
 
Hi Manuel,

You should load concurrency fields after your insert executes.
 
Thanks for replying to this one Miha.

When you say that I should load concurrency field after the insert. Cam you
give a hint on how can I accomplish this?

Thanks,

Manuel

Miha Markic said:
Hi Manuel,

You should load concurrency fields after your insert executes.

--
Miha Markic [MVP C#] - RightHand .NET consulting & development
miha at rthand com
www.rthand.com

Manuel Canas said:
Hi All,

After I call a data adapter for a straight insert on the DB, if I call the
same data adapter for an update on the same record, it throws an concurency
error saying that the update command updated 0 rows.

Now, how do I release and initialize it again so I can update that record
right after the insert command?

Thanks very much for you input on this one.

Manuel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top