Monday 1 November 2021

if A={1,3,5} and B={2,4,6} than A-B=? B-A=? (VMOU MSCCS/PGDCA/CAWD/MCA I Year - December 2018 Q5 Application software and web designing )


Question: if A={1,3,5} and B={2,4,6} than A-B=? B-A=?

Answer:-

Difference(–):- 

  • Difference operator को –  चिन्‍ह द्वारा दर्शाया जाता है।

Difference operator represented by - symbol in relational algebra.


  • इसका syntax निम्नलिखित है:- Syntax is
    [ R=P–Q]
  • Difference operation, Relation/Table 1 व Relation/Table 2 में स्‍टोर कॉमन tuples/rows  को हटा देता है। जिसके कारण आउटपुट में केवल Relation/Table 1 की शेष Rows/Tuples प्राप्‍त होगी। हम इसे निम्न चित्र के द्वारा आसानी से समझ सकते हैं।

In difference operation common rows of both relation 1 & 2 eliminated and get only uncommon rows/tuples from relation 1 in output. Shown in diagram properly.

 

As per above statement A-B= {1, 3, 5} and B-A= {2, 4, 6}

उपर्युक्‍त परिभाषा अनुसार डिफरेन्‍स ऑपरेटर का प्रयोग करने पर A-B= {1, 3, 5} and B-A= {2, 4, 6} परिणाम प्राप्‍त होगें।

No comments:

Post a Comment