kvarnerexpress 0 Report post Posted September 10, 2005 Can someone point me to an example in C# that does the following (I will use the Northwind database to explain), using a DataSet:1.) Add a Customer to the Customers table.2.) Add an Order to the Orders table with that new Customer's CustomerID.Basically, what I am not sure how to do, is figure out what the CustomerID is before adding the record to the Orders table. I thought I could do both 1 and 2 inside the DataSet, before calling Update, is this true? Or do I need to call Update after adding the customer in order for a CustomerID to be generated, and then do another Select statement to retrieve the CustomerID?I have seen a lot of examples of updating records in the Northwind database, but I haven't been able to find a sample that adds new records in both Customers and Orders.Thanks!kvarnerexpress Share this post Link to post Share on other sites