Reputation: 388
What are the consequences of eliminating duplicates in Projection Operator?And yes, why there is no duplicate elimination in real systems, unless specified?
Upvotes: 13
Views: 16294
Reputation: 31
As Martin suggested, Relational Algebra deals with sets, projection, selection, union, intersection are all SET operations. And sets don't have duplicates. However real world systems take into considerations tuples or multisets, which can have duplicates.
Upvotes: 3
Reputation: 18408
If something is true, then saying it twice won't make it any truer.
The required duplicate elimination was left out of the early implementations of "relational" systems because the engineers were afraid of the performance implications. And even when keywords like DISTINCT were newly introduced / newly supported in an existing system, the algorithms used for it were typically so naive that "performance implications" appeared to be very real and/or inevitable. Things have remained like that ever since.
Upvotes: 8