SELECT with MINUS
634069Jun 9 2008 — edited Jun 26 2008Hi All,
I have two tables with the following records
ORG_TAB
org_id org_name
--------- --------------
1 One
2 Two
3 Three
4 Four
SUP_ORG_TAB
sup_id org_id
---------- ---------
101 1
101 4
102 2
102 3
103 1
Now, my problem is to create a select statement that would show me all the org_id/org_name on ORG_TAB that is not present in the group of sup_id (org_id)
RESULT
sup_id org_name
------------- ------------
101 Two
101 Three
102 One
102 Four
103 Two
103 Three
103 Four
Hopefully you can help me on this.
Cheers,
Roderick