Professional Documents
Culture Documents
Relational Model
Relation, Tuple, Attribute, Domain
Record Identification Keys
Record Relationship Keys
Relational database (RDB)
Relational Database Management System (RDBMS)
Department Employee
DID DName EID EName DID
13 Marketing 15 John Smith 13
14 Accounts 16 Mary Brown 14
15 Personnel 17 Mark Jones 13
18 Jane Smith NULL
Domain constraint
Primary keys
can never have
NULL values
The rule states that if there is a foreign key in one relation, either
each foreign key value must match a primary key value in
another relation or the foreign key value must be null.
A2
A1 v3
v1 v5
v2 v1
v3 v6
v4 v2
null v7
v3 v4
R1 R2
Foreign key
(or key reference) Primary key