Search code examples
databasedatabase-designfunctional-dependencieserd

Determining functional dependencies from an ER diagram


I have to determine the functional dependencies for the below ER: enter image description here

As shown It's a one-to-many relationship. Depending on the functional dependency definition:

"X->Y means, each possible value of X can correspond to exactly one value of Y"

, I can write:

A -> B
P -> Q,R

But I'm not sure how should the FD should be written for Ent1 and Ent1 with the relation. If I write A -> X,Pis it correct?. Can someone explain?

Thank you.


Solution

  • In any relationship, the combination of entity sets in many-roles determine the other entity sets and attributes in the relationship.

    In your example, Ent2 (represented by P) determines Ent1 (represented by A) as well as X.

    So, you would write P -> A,X.