Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
More than one field.
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
00865244
Message ID:
00865257
Vues:
19
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
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform