intersect package:rel8
Find the intersection of two queries, collapsing duplicates.
intersect a b is the same as the SQL statement a
INTERSECT b.
Find the intersection of two queries, retaining duplicates.
intersectAll a b is the same as the SQL statement a
INTERSECT ALL b.