0
0
DBMS Theoryknowledge~5 mins

Union, intersection, difference in DBMS Theory - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the UNION operation in set theory or databases?
UNION combines all unique elements from two sets or tables, removing duplicates to form a single set.
Click to reveal answer
beginner
Define INTERSECTION in the context of databases.
INTERSECTION returns only the elements that appear in both sets or tables.
Click to reveal answer
beginner
What does the DIFFERENCE operation do?
DIFFERENCE returns elements that are in the first set but not in the second set.
Click to reveal answer
intermediate
How does UNION handle duplicate records in database tables?
UNION removes duplicate records, so each record appears only once in the result.
Click to reveal answer
intermediate
Can INTERSECTION be used to find common customers in two sales tables?
Yes, INTERSECTION returns customers present in both sales tables, showing common entries.
Click to reveal answer
Which operation returns all unique records from two tables combined?
AINTERSECTION
BUNION
CDIFFERENCE
DJOIN
What does INTERSECTION return when applied to two sets?
AElements only in the first set
BElements only in the second set
CElements common to both sets
DAll elements from both sets
If you want to find records in Table A but not in Table B, which operation do you use?
AUNION
BINTERSECTION
CCROSS JOIN
DDIFFERENCE
Does UNION include duplicate records in the result?
ANo, duplicates are removed
BYes, all duplicates are included
COnly duplicates from the first set are included
DOnly duplicates from the second set are included
Which operation would you use to find customers who bought products from both Store A and Store B?
AINTERSECTION
BUNION
CDIFFERENCE
DFULL OUTER JOIN
Explain the difference between UNION, INTERSECTION, and DIFFERENCE operations with examples.
Think about combining lists, finding common friends, or removing items.
You got /4 concepts.
    How can UNION, INTERSECTION, and DIFFERENCE be useful in managing data in databases?
    Consider scenarios like combining customer lists or comparing inventories.
    You got /4 concepts.