Wednesday, September 14, 2016

Which of the relational algebra operations are eliminating duplicates

Which of the relational algebra operations are eliminating duplicates?


Question:


8. Which of the following Relational Algebra operations is/are eliminating duplicates?

(a) SELECTION (σ)
(b) PROJECTION (∏)
(c) UNION (U)
(d) All of the above



Answer:

Both (b) and (c)

In relational algebra, a relation (table) is considered as a set. According to the set theory, a set cannot have duplicates. That is, "A set is a collection of well defined and distinct objects". PROJECTION is about picking up some attributes and they may show duplicates. Also, UNION operation simply joins two relations into one if both relations have same number of compatible attributes. If a tuple in one relation is same as the one in the other, then duplicates are possible. Hence, we need to eliminate duplicates to comply with set theory concepts. So, PROJECTION and UNION eliminates duplicates

SELECTION operation filters tuples (records) as per the given condition. A relation as a set cannot have two tuples similar. Hence, selection need not remove duplicates as there are no duplicate records.







         Previous Question                                                                                Next Question


No comments:

Post a Comment

Featured Content

Multiple choice questions in Natural Language Processing Home

MCQ in Natural Language Processing, Quiz questions with answers in NLP, Top interview questions in NLP with answers Multiple Choice Que...

All time most popular contents

data recovery