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.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Help with query

Author  Topic 

raxbat
Yak Posting Veteran

52 Posts

Posted - 2007-11-30 : 02:06:21
Hello!
I have two tables:
Objects(Code, device_id) and Signals(Code, device_id, time)
Objects is the database of all devices that is linked to Codes. In table Signals maybe Codes with device_id different from correct data in table Objects. So I need to query all Codes from table Signals, which are not in table Objects.

Help me please!
Thank You

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-11-30 : 02:11:25
select code from signals where code not in (select code from objects)
Go to Top of Page

raxbat
Yak Posting Veteran

52 Posts

Posted - 2007-11-30 : 02:15:25
thanx
Go to Top of Page
   

- Advertisement -