Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Compare Tables
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00614962
Message ID:
00615226
Vues:
26
Randall,

A faster way to do this:
select tableA.* ;
   from tableA ;
   into cursor missing ;
   where not exists ;
   ( select keyfield from tableB where tableB.keyfield = tableA.keyfield )
NOT IN requires much more work to be done by the SQL engine.

>I just thought about it. This does give me a table with everyrthing that is there but I still will have not idea of what's missing. For example, table A has 100,000 records in it. The result table gomes up with 95,000 matches. How do I know of the 5000 records in table A are missing in table B? I was thinking I could mark them some how. Then I would have a table of what was not in there. Maybe I could change the code to say NOT IN?
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform