UNION
will eliminate duplicate rows, whether they come between the two result sets or, as in your case, within just one result set. Try using UNION ALL
instead.
UNION
will eliminate duplicate rows, whether they come between the two result sets or, as in your case, within just one result set. Try using UNION ALL
instead.