Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
More than one field.
Message
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Miscellaneous
Thread ID:
00865244
Message ID:
00865257
Views:
20
You could do it like this:

select * from table1
where field1 not in (select field1 from table2) and
field1 not in (select field2 from table2) and
field1 not in (select field3 from table2)

That will return a row if table1.field1 is not equal to any field in table2.

>Is there a way to use more than one field when I determine if a record is not in a specific subquerey? For example:
>
> select * from table1 where field1 not in(select * from table2)
>
>I would like check all of the fields from table1 and determine if that EXACT record is contained in table2.
>
>Thanks in advance
>Kelly
Previous
Reply
Map
View

Click here to load this message in the networking platform