22.9. Multitabled DataSet Objects and Data Relationships

So far, all of this chapter's examples have operated on a single DataTable object. However, the power of the disconnected layer shines through when a DataSet object contains numerous interrelated DataTables. In this case, you can define any number of DataRelation objects in the DataSet's DataRelation collection to account for the interdependencies of the tables. The client tier can use these objects to navigate between the table data without incurring network roundtrips.

NOTE

Rather than updating AutoLotDAL.dll to account for the Customers and Orders tables, this example isolates all of the data access logic within a new Windows Forms project. However, intermixing UI and data logic in ...

Get Pro C# 2010 and the .NET 4 Platform, Fifth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.