Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
jscot
Posting Yak Master
106 Posts |
Posted - 2011-06-18 : 00:29:26
|
| Here is my sample tableTable AID CID OID1 23 562 45 213 44 33Table BID CID OID1 23 562 44 33Here is my question, How i can find out OID don't have in Table B. I know one way i can do to find out which Oid don't have in Table B is NOT IN syntax,Is there other way ? |
|
|
sunitabeck
Master Smack Fu Yak Hacker
5155 Posts |
Posted - 2011-06-18 : 06:31:54
|
Are you running into any performance or other problems with using "NOT IN"? In any case, another alternative would be to use a left join as in:select a.*from a left join b on a.oid = b.oidwhere b.oid is null |
 |
|
|
|
|
|