Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem: Showing data from multiple source-tables in a g
Message
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Miscellaneous
Thread ID:
00920676
Message ID:
00935544
Views:
60
Mat,

"Doesn't this get back to the original problem of updating multiple tables with a single dataset?"

No, because I don't save that dataset(actually it is just a datatable).

If data comes from 3 tables, I make 3 queries where each query only selects fields from one table each, and databind the textboxes to these datasets.

To display data from all these 3 datasets in the grid, I create a datatable and populate it with the fields I want to show in the grid(using the LoadDataRow-method), and then databind the grid to the datatable.

When the user changes something in a textbox, I update the datatable the grid is bound to. When the user changes something in the grid, I update the datasets the textboxes are bound to(not by saving, but just by copying the data from the datatable to the datasets).

This way I get the read-write grid that I wanted, and I don't have to make an extra SQL-JOIN query and pull data from the database twice.

Kind Regards,
Christian
Previous
Reply
Map
View

Click here to load this message in the networking platform