Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
>>Al alternative if what you really wanted was the two tables merged without any duplicates would be to UNION them together then do a GROUP BY on every field in the table. The result is all records from both tables without duplicates.
>
>Isn't the default union clause distinct? That is to say, it only grabs one record if there are two or more dups?
You are right. I never noticed that before.
From VFP6 Help
=============================
[UNION [ALL] SELECTCommand]
Combines the final results of one SELECT with the final results of another SELECT. By default, UNION checks the combined results and eliminates duplicate rows. Use parentheses to combine multiple UNION clauses.
ALL prevents UNION from eliminating duplicate rows from the combined results.
============================
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement