Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with GROUP BY in VFP 9
Message
De
24/06/2005 16:02:56
 
 
À
24/06/2005 13:25:47
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
01026374
Message ID:
01026439
Vues:
18
>Since I could not search for Group By (is there a way to do this) I searched of select group and could not find why the following syntax (which works in VFP 7 does not work in VFP 9.
>
>SELECT						;
>	piitems.clstkno ,			;
>	instock.cdescript ,			;
>	piitems.nreqqty AS nreqqty ,		;
>	piitems.cuomissu ,			;
>	instock.nqty ,				;
>	piitems.ddatestamp			;
>	FROM 	piitems , instock		;
>	WHERE 	piitems.ddatestamp = issueddate	;
>	AND ALLTRIM(UPPER(piitems.clstkno)) = 	;
>		ALLTRIM(UPPER(instock.cstkno))	;
>	AND piitems.csitecode = gcsitecode	;
>	ORDER BY piitems.clstkno  		;
>	GROUP BY piitems.clstkno		;
>	INTO CURSOR dailyissues
>
>I get an error message that "GROUP BY clause is missing or invalid (error 1807). The help file is not very helpful. I also tried "GROUP BY 1" and get the same error message. What am I missing.

Claude - the real question is why you'd be grouping in this query. You don't have any aggregate functions (SUM(), AVG(), etc.), so what's the point of grouping the records.

Tamar
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform