Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Creating a table of all duplicates in a dbf file
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00445501
Message ID:
00445502
Vues:
26
>I know that I can create a unique.dbf from a dbf file that contains all unique records based on one field or multiple fields.
>
>But how would I create a dbf (using a query) that would give me a table with all duplicated files. For example if a record appeared 3 times I would like to have that in a seperate table with all 3 records. I need this to show my customers how many duplicates they have in their database. This also allows them to determine which record should be used or removed.
>
>Thanks
>
>Peter

Try this:

SELECT * FROM TableName ;
WHERE Name IN (SELECT Name FROM TableName GROUP BY Name HAVING COUNT(*) > ) ;
INTO TABLE Duplicates
Chris McCandless
Red Sky Software
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform