Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Group By Example in VFP 8
Message
De
22/07/2004 16:36:29
Luis Navas
Independent Consultant
Auckland, Nouvelle Zélande
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00926827
Message ID:
00927177
Vues:
19
>>Thanks Craig, but in this way SELECT returnm me the same number of records as without the Group By Clause, before with Set Enginebehavior 70 and only writing codpai in the Group By it gives me 19, and writing what you told me it gives me 1410 Records.
>>Thanks for your time
>>Luis Navas
>>>The GROUP BY must include all the fields in the SELECT that are not aggregate fields (SUM, AVG, etc).
>>>
>>>GROUP BY Codpai, Codven, Valpedmn, Fecped, Nompai, Nomven
>>>
>
>That's because the values of Codven, Valpedmn, Fecped, Nompai and Nomven are not all the same for each value of Codpai. With the old way, you had no guarantee of what values would be in these other fields. The old way also was not ANSI SQL compliant.


Thanks, but what if want to group on Codven and I donsen't care if the other values are the same?
Luis
I never forget a face, but in your case I will make an exception :-)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform