Return the union of the specified result sets. We will remove the results that match the optional
exception result sets. But this operation does not result in duplicate results as it performs
deduplication.
Note: You should use the unionAll operation whenever possible. Using it enables a built-in optimization.
I.e. A unionAll B with limit: n will execute set operation B, if and only if, A returns less than
n records.
Return the union of the specified result sets. We will remove the results that match the optional exception result sets. But this operation does not result in duplicate results as it performs deduplication.
Note: You should use the
unionAll
operation whenever possible. Using it enables a built-in optimization. I.e.A unionAll B
withlimit: n
will execute set operation B, if and only if, A returns less than n records.