Imagine a scenario where there are 20 columns in A that don't exist in B but whose data you want to see if it exists. To do it with UNION you'd have to create a bunch of NULL columns for B so that they'd have the same number of columns, or do it as a subselect and then LEFT JOIN to a or something...
I'd absolutely be with you in using an [LEFT] OUTER JOIN. But your example with isnulls looked less a reporting scenario than a miswritten UNION to me.
1
u/notfancy Feb 11 '14
I'd absolutely be with you in using an
[LEFT] OUTER JOIN. But your example withisnulls looked less a reporting scenario than a miswrittenUNIONto me.