Parent-Child relations in a dataset
From: Mark G (anonymous_at_discussions.microsoft.com)
Date: 04/15/04
- Next message: alex: "Microsoft Data Access Application Block"
- Previous message: suzy: "Re: whats the best way to do this?"
- Next in thread: David Sceppa: "RE: Parent-Child relations in a dataset"
- Reply: David Sceppa: "RE: Parent-Child relations in a dataset"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 15 Apr 2004 03:26:04 -0700
I'm facing the following problem:
The dataset contains two tables (parent-child), and both tables have auto-incrementing column (SID).
I succeed to insert a row into the parent table (in the dataset and in the db), but when I try to get the value of the SID (from the dataset, before updating the dataset), I'm recieving 0 as a value;
and then addition of the child rows fails ("system error") - I succeed to add new rows to corresponding datatable, but updating this table thru a dataadpter fails .
By the way, I'm using the typed dataset.
Questions:
1. Where do I go wrong?
2. What is the right way to insert new records in 'parent-child-typed-dataset' scenario?
- Next message: alex: "Microsoft Data Access Application Block"
- Previous message: suzy: "Re: whats the best way to do this?"
- Next in thread: David Sceppa: "RE: Parent-Child relations in a dataset"
- Reply: David Sceppa: "RE: Parent-Child relations in a dataset"
- Messages sorted by: [ date ] [ thread ]