I don't know which way you use in order to fill the dataset, but understand this - ado.net doesn't search your dataset for the "best suitable" datatable to hold the returned rows, you need to "notify" the query to which datatable it should insert the returned rows, otherwise it will just create a new datatable and put the rows there. Because you didn't mention the way you run your queries (directly using commands and dataAdapters, using DAAB or the new Enterprise Library etc.).
One option you might want to try is this :
1. Load the data into a new dataset (general one, not a typed one)
2. Use the Merge method of the datatable, in order to copy the data to the typed one. for example:
MyTDS.Patients.Merge(ds.Tables[0]);
Ido.
|