I have a tough SQL join query and I figured it out, so I thought you
might find it useful.
I have 3 tables with tracking numbers in them. I want to think of the
sum of all these tracking numbers, then find non-matches to a master
tracking number table. When I find non-matches (orphans) in the master
tracking number table, I want to eliminate the orphans.
The master table is "master_tn". The column in question is "tn"
(tracking number).
((select tn from master_tn except select tn from opentickets) except
select tn from voidedtickets) except select tn from resolvedtickets
There you go. Enjoy!
If anyone can optimize that even better, I would welcome it.