Database Reference
In-Depth Information
Figure 10.1. A pair of logically related tables
A logical relationship exists between the data in the STUDENTS table and the data
in the STUDENT INSTRUMENTS table. A student can check out one or more in-
struments during the course of a school year, so a record in the STUDENTS table
(representing the student) can be related to one or more records in the STUDENT
INSTRUMENTS table (representing the particular instruments the student checks
out).
It helps to further refine table structures and minimize redundant data. As you es-
tablish a relationship between a pair of tables, you will inevitably make minor
modifications to the table structures. These refinements will make the structures
more efficient and minimize any redundant data that the tables may contain.
It is the mechanism that enables you to draw data from multiple tables simultan-
eously. In Chapter 12 , “ Views , ” you'll learn how a relationship enables you to con-
struct a view using fields from two or more related tables.
A properly defined relationship ensures relationship-level integrity, which guarantees that
the relationship itself is reliable and sound. (Recall that relationship-level integrity is a
component of overall data integrity.) You can take advantage of the many benefits a rela-
tional database provides only when you establish each relationship carefully and properly.
Failure to do so means that you'll have a hard and tedious time working with data from
multiple tables, and you'll certainly encounter problems when you try to insert, update, or
deleterecordsinrelatedtables.You'lllearnmoreaboutthesetypesofproblemslaterasthe
design process unfolds.
Search WWH ::




Custom Search