Data Table Structure

Certainly, the primary collection exposed by a DataSet is encapsulated in the DataTableCollection object and exposed through the Tables property. The DataTableCollection object in turn exposes DataTable objects that are used to cache the data within the DataSet. In this section, you'll learn how that data is exposed through rows and columns and how you can customize the properties of the table to assist in maintaining data integrity.

As you might imagine, the DataTable exposes some members that are similar to those found in the DataSet. The reason for this overlap is that the members of the DataSet, such as HasErrors, look at all tables within the DataSet, whereas the DataTable properties are particular to an instance. The ...

Get Sams Teach Yourself ADO.NET in 21 Days 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.