Non "Trivial" Dataset Operations

D

Dave

Does anyone know of any good online examples of using
DataAdapter.Update when your dataset operations are not
the "trival" case where SELECT, INSERT, UPDATE and DELETE
are applied to all tables in a typed dataset?

Say for example your typed dataset has two tables "First"
and "Second". Your SELECT command should have SELECT
stored procedures for "First" and "Second" but your UPDATE
command stored procedure would only UPDATE "Second" and
the INSERT command would only INSERT into "First".

I find I have a lot of problems with parameters not
supplied, etc. when I try to do this kind of thing.
 
W

William \(Bill\) Vaughn

Ideally, you should follow the design for the DataAdapter and use a separate
DA for each table. This way no one (not even ADO.NET) is confused as to
which table needs to be updated or changed with the Update method. My book
has examples that go beyond the "trivial" case and I have a new article
published in VSJ (September/October) that discusses the DA in more depth.

hth

--
____________________________________
Bill Vaughn
MVP, hRD
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 

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

Top