Kirbbbb
Kirbbbb

Reputation: 133

Is this table in 1NF or 2NF?

Supposed i have a relational table:

FinalYearProject(supervisor, researchTopic, consultationDay, student)

and the following functional dependencies:

    student -> researchTopic
    student, researchTopic -> supervisor
    researchTopic,supervisor -> consultationDay 

From there i determined my minimal superkey is: student where

student -> researchTopic,supervisor, consultationDay

Is it right for me to say that there is partial dependency as supervisor do not depend solely on student based on the functional dependency:

student, researchTopic -> supervisor

Any help will be greatly appreciated.

Upvotes: 0

Views: 154

Answers (1)

Renzo
Renzo

Reputation: 27424

Since student is the candidate key, supervisor depends on it.

In fact, consider that, given student -> researchTopic, the research topic depends on the student: so in the dependency student, researchTopic -> supervisor the attribute researchTopic is superfluous (the depedency student -> supervisor holds). It is easy to show this by using the Armstrong’s Axioms.

And since a relation is not in 2NF when a non-prime attribute is functionally dependent on a proper subset of a candidate key, there is no such case in this example, and the relation is in 2NF.

Upvotes: 2

Related Questions