2

I have the following relation and function dependencies.

R = ABCDE
F: C->AB, D->A, BE->CE, E->B

I have to check whether this relation is in BCNF.

Wikipedia states:

...if and only if for every one of its dependencies X → Y, at least one of the following conditions hold:[4] X → Y is a trivial functional dependency (Y ⊆ X) X is a superkey for schema R

So first I went on to find the superkeys.

Since D is not on the right side, I'm assuming the superkey must contain D in it.

What I thought is that the only superkey is DE. Is this correct?

And if the only superkey is DE, then the relation is not in BCNF because none of the functional dependencies have the superkey on the left.

Can anyone point out if I'm mistaken?

  • I guess you mean the DE is the only minimal superkey. But why isn't DC too? How did you get to this result? Why isn't DB or DA or DAB a superkey as well? – ypercubeᵀᴹ Dec 4 '12 at 13:34
  • Another question you should consider: is R in 3NF? Is it in 2NF? If not, it's surely not in BCNF either. – ypercubeᵀᴹ Dec 4 '12 at 13:45
  • DC is not for sure, because CLOSURE(DC, F) = DCAB. I got this result by trying out the combinations DA, DB, DC, DE and finding that only DE is the superkey. I'm curious whether my way to directly check if this relation is in BCNF is correct (I don't want to test for 3NF/2NF). – Tool Dec 4 '12 at 14:08
  • Again; you mean minimal superkey. The whole R ABCDE is trivially a superkey, too, so DE cannot be the only superkey. – ypercubeᵀᴹ Dec 4 '12 at 14:10
  • 1
    You're right - but I'm still curious about whether my conclusion that this relation IS NOT in BCNF - based on the fact that the minimal superkey is DE - is correct? Or can checking for BCNF be done differently? – Tool Dec 4 '12 at 14:12
3

"Armstrong's axioms are a set of axioms (or, more precisely, inference rules) used to infer all the functional dependencies on a relational database"(link).

  • R: ABCDE
  • F: C->AB, D->A, BE->CE, E->B

BE->CE can be split in BE->C and BE->E. The trivial functional dependency BE->E can be skipped. BE->C can be replaced by E->C because from BE->C and E->B one can deduce E->C. Therefore the set of functional dependencies can be reduced to:

  • R: ABCDE
  • F: C->AB, D->A, E->C, E->B

A and B cannot be member of a key because they cannot be found on the left site of a functional dependency. So it is sufficient to search all keys of the relational system (remove the Attributes A B from R and all functional dependencies containing A and B)

  • R: CDE
  • F: E->C

C is not on the left side of a functional dependcy so again one can reduce the system to

  • R: DE
  • F:

So the list F of functional identities is empty. The only key of this relational system is DE which is also the only key of the unreduced systems. So your answer of your first question is true.

You can use this page to find your candidate keys

To check if the system is in BCNF it is not necessary to find all candidate keys. It is sufficient to find one functional dependency which has a left side that is no a key.

C->AB is such a functional dependency: C is not a key because the closure of C is C. This means that no further attributes can be generated by applying functional dependencies on C.

You can use this page to find check if a relation is in normal form.

| improve this answer | |
  • But the question does not say that the given set of FDs is a cover; you are unjustifiably assuming it. So although Armstrong's axioms tell us that further FDs hold because the given ones do, we don't know whether any other FDs hold, so we don't know CKs or highest NF. – philipxy Jan 9 '19 at 9:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.