Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Registros Duplicados
Message
De
07/06/2003 14:03:16
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00797664
Message ID:
00797665
Vues:
12
>Disculpen, en alguna ocasion vi unos datos acerca de como detectar registros duplicados en una base de datos empleando select de SQL...
>Alguien me puede ubicar el No. de conversación, si es que lo tiene a la mano ?....

No recuerdo, pero una manera fácil es un SELECT - SQL con la cláusula GROUP BY.

Supongamos que el número de cliente, en la tabla de clientes, supuestamente es duplicado. El código sería algo así como:
select NumCliente, count(*) as NumVeces;
  from Clientes;
  group by NumCliente;
  order by NumVeces descending;
  where NumVeces > 1;
  into cursor Temp
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform