|
|
We will spend a few lectures studying functional dependencies and their applications before discussion the 2NF and 3NF
X → Y <=> for any two tuples t1 and t2 of the relation R: if t1[X] = t2[X] then: t1[Y] = t2[Y] |
I.e.: whenever you see the same attribute value in X then you must see the same attribute value in Y also.
Employee1(SSN, FName, LName, PNumber, PName, Hours) |
that stores information about the employees AND the projects that an employee works on.
The key of this relation is: (SSN, PNumber)
SSN | FName | LName | PNumber | PName | Hours |
---|---|---|---|---|---|
111-11-1111 | John | Smith | pj1 | DBApplet | 20 |
111-11-1111 | John | Smith | pj2 | WebServer | 10 |
111-22-3333 | Jane | Doe | pj1 | DBApplet | 5 |
|
Explanation:
SSN, PNumber → fname, lname is valid because: whenever we have the same values for (SSN, PNumber), we will also have the same value for (fname, lname) (The attribute SSN is sufficient for the functional dependency, adding PNumber to SSN will not break the functional dependency) |
|
|