Database Relationships and Constraints
Before discussing how to create data relations inside a DataSet, it makes sense to explain how relationships function inside a relational database system such as Microsoft SQL Server. If you are already familiar with relational databases, you might want to skip ahead to the section entitled “The DataRelation Object.”
Relationships
Suppose you have to store information about customer orders inside a database. You might choose to use a database schema like the one shown in the database diagram in Figure 4.1. There are five tables in this diagram, and they are all related to the main Orders table. Notice the lines connecting the tables together. Each of these lines represents a relationship in the database. ...
Get Sams Teach Yourself ADO.NET in 24 Hours 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.