Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to change JOIN to exclude?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01339003
Message ID:
01339030
Vues:
14
This message has been marked as a message which has helped to the initial question of the thread.
>>
>>select mt1.* from mytable1 mt1 LEFT join mytable2 mt2 on mt1.fld1 = mt2.fld1 ;
>>	WHERE mt2.fld1 IS NULL
>>
>>>
>
>Thank you.


Two more wais
select mt1.* from mytable1 mt1 ;
	WHERE NOT EXIST ( SELECT * FROM mytable2 mt2;
		WHERE mt1.fld1 = mt2.fld1)

*or 
	
select * from mytable1  ;
	WHERE fld1 NOT IN ( SELECT fld1 FROM mytable2)
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform