Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select distinct not the answer
Message
De
16/05/2012 11:21:03
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Select distinct not the answer
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Divers
Thread ID:
01543687
Message ID:
01543687
Vues:
62
Hi All:

I have a table where there are dupes in a particular column, FOO. I want to create a cursor that will contain only one record per FOO, so I coded:
SELECT * ;
FROM ImpHeader ;
ORDER BY FOO ;
GROUP BY FOO ;
INTO CURSOR curHeader READWRITE
VFP doesn't like the GROUP BY, but it is a pain to GROUP BY all the other fields or aggregate them. I do need the data from the other fields, so SELECT DISTINCT FOO would not help.

What is the solution?

Thanks,

Yossi
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform