|
|
|
|
|
Referential IntegrityReferential integrity is a concept used when dealing with relational databases. Referential integrity is usually enforced with a primary and foreign key combination. One field in a table is declared to be the foreign key. It can only contain values that are primary keys in another table, its parent table. The relational database management system (RDBMS) must take care that modifications to the parent table does not break the referential integrity which could happen if an item in the parent table is deleted that is referred to by a foreign key. Example In a database that consists of employees and departments, it is then useful to know in which department each employee work. A foreign key "Department#" could be created in the Employee table that was only allowed to refer to a primary key in the Department table. Enforcing referential integrity would forbid a department being deleted from the Department table if employees listed in the Employee table are refering to it. See also External links - http://www.frick-cpa.com/ss7/Theory_DataIntegrity.asp#Referential
|
 |
|
| Copyright 2005-2009 OnPedia.com. All Rights Reserved |
|
|