Database Reference
In-Depth Information
Let us ask the questions the other way around. Does the value of the attribute
Position uniquely and functionally determine the value of the primary key attribute?
Attribute value Analyst does not uniquely determine a key value—in this
case,
it determines two values of the key,
namely,
213-36-7854 and
311-33-4520.
What you see clearly is that the value of the primary key uniquely and
functionally determines the values of other attributes, and not the other way
around.
Let us express this concept with a functional dependency notation
FD: SocSecNumber
Æ
EmployeeName
FD: SocSecNumber
Æ
Position
In the ASSIGNMENT relation, two attributes, SocSecNumber and ProjectID,
together make up the primary key. Here, too, the values of the other attribute
in the tuple are uniquely determined by the values of the composite primary
key.
FD: SocSecNumber, ProjID
Æ
StrtDate
The discussion of functional dependencies leads to another important rule or
constraint for the primary key of a relation.
Functional dependency rule : Each data item in a tuple of a relation is uniquely and
functionally determined by the primary key, by the whole primary key, and only by the
primary key.
DATA MANIPULATION
What is the motivation for creating a database system for an organization? Why do
you examine all the information requirements, create a data model to reflect the
information requirements, and build a database system based on the designed data
model? Of course, the reason is to provide users with the ability to access the data,
share it, and use it to perform the various business processes. The database is meant
for usage—read data, change data, add data, and also delete data from the database
as needed.
The structure of the relational model in the form of two-dimensional tables rests
on a solid mathematical foundation. Can mathematical principles and methods
based on the set theory be used to retrieve data from a database built on the rela-
tional model? How can you manipulate data? Are there sound languages to inter-
face with the database and work with the data in the database?
Dr. Codd, who formulated the structure and rules of the relational model, also
provided methods for data manipulation in a relational database. He suggested lan-
guages for doing so. We will now examine these languages and appreciate the robust
mathematical foundation on which the languages stand.
Search WWH ::




Custom Search