Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Showing Only Duplicates
Message
 
 
À
01/12/2001 10:54:58
Carmen Gassi
Perseus Software Systems
Oakville, Ontario, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00588383
Message ID:
00588389
Vues:
24
This message has been marked as the solution to the initial question of the thread.
>I thank all in advance for any help. I have been asked to provide a screen lookup, or browse window where the user would like to filter and show only the records where a specific field has duplicates. Is it possible to do in an SQL, or do I have to write a function to extract the duplicates first, then simply browse those?

Hi Carmen,
If you want only display duplicates than
SELECT * FROM mytable ;
  WHERE KeyField1 IN ( ;
    SELECT KeyField1 FROM mytable GROUP BY 1 HAVING COUNT(*) > 1 ) ;
  INTO CURSOR crsDups
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform