dbTalk Databases Forums  

satisfies algorithm

comp.databases.theory comp.databases.theory


Discuss satisfies algorithm in the comp.databases.theory forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
aarklon@gmail.com
 
Posts: n/a

Default satisfies algorithm - 07-25-2008 , 07:41 AM






Hi all,


the following is the algorithm which i saw in schaum series
book(fundamentals of relational databases)

satisfies algorithm

this algorithm shown below can be used to determine if a relation r
satisfies or does not satisfies a given functional dependency A -> B.
the input to the algorithm is a given relation r and a functional
dependency A -> B. the output of the algorithm is true if r satisfies
A -> B; otherwise the output is false.

1) sort the tuples of the relation r on the A attribute(s) so that
tuples with equal values under A are next to each other

2) check that tuples with equal values under attribute(s) A also have
equal values under attribute(s) B

3) if any tuples of r meet condition 1 but fail to meet condition 2
the output of the algorithm is false. otherwise, the relation
satisfies the functional dependency and the o/p of the algorithm is
true.

now my question is there any other better method (other than inference
axioms) ?

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.