Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Register Now and get your question answered!
Save Password
Forgot your Password?

 All Forums
 Old Forums
 CLOSED - General SQL Server
 select records from a table that isnt in other
 Forum Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Posting Yak Master

157 Posts

Posted - 07/06/2006 :  12:53:47  Show Profile  Send shifis a Yahoo! Message
Hi, i got brain freeze and dont know how to solve my problem.

I got 2 tables with the same type of data, what i need is select the records that are in the first table but arent in the second.

Any idea will be helpful.

Not Just a Number

15586 Posts

Posted - 07/06/2006 :  13:02:07  Show Profile
SELECT * FROM table1 a WHERE NOT EXISTS (SELECT * FROM table2 b WHERE a.key = b.key)



Hint: Want your questions answered fast? Follow the direction in this link

Add yourself!
Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000