Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
New SQL: What's with the GROUP BY error?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00853362
Message ID:
00853381
Vues:
21
>To use a group by, you need an aggregate function in the SELECT field list like MAX(), MIN(), COUNT(*), etc. Once you have that, then every other field that is not aggregated, must be in the GROUP BY clause. Other wise, see SET ENGINEBEHAVIOR in VFP Help file.


Yup, pasted the wrong code sample...same error with the below.
SELECT Detail.*, count(*) as Total, Codes.desc;
 FROM ;
     detail ;
    LEFT OUTER JOIN codes ;
   ON  Detail.bccode = Codes.code;
 GROUP BY Detail.bccode;
 ORDER BY Detail.bccode
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform