Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
NOT Equal to
Message
De
12/07/2003 07:24:48
 
 
À
12/07/2003 03:21:04
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Divers
Thread ID:
00809537
Message ID:
00809552
Vues:
35
Hi

>two tables have same structure. One table has more records that not in other table. I want to get those records. I wrote this SQL query but got Cartision product.
>
>SELECT ffs.ccod, ffs.cnam, smc.ccod, smc.cnam from ffs, smc WHERE ffs.ccod<>smc.ccod

Easiest way is to use a sub-query like this:
SELECT ffs.ccod, ffs.cnam, smc.ccod, smc.cnam 
  FROM ffs
 WHERE ffs.ccod NOT IN (SELECT ccod FROM smc)
----
Regards
Andy Kramek
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform