Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Group By Example in VFP 8
Message
From
22/07/2004 19:49:08
Mike Yearwood
Toronto, Ontario, Canada
 
 
To
22/07/2004 19:27:47
Luis Navas
Independent Consultant
Auckland, New Zealand
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00926827
Message ID:
00927241
Views:
18
>>
>>Select	Pedidos.Codpai				;
>>	,	Pedidos.Codven			;
>>	,	MAX(Maepai.nompai)		;
>>	,	MAX(Maeven.nomven)		;
>>	,	MAX(Pedidos.Valpedmn)		;	&& what is this ?
>>	,	MIN(Pedidos.Fecped)	MinFecped	;
>>	,	MAX(Pedidos.Fecped)	MaxFecped	;
>>	,	SUM(Iif(Month(fecped)=1,valpedmn,0)) As enero	;
>>	,	SUM(Iif(Month(fecped)=2,valpedmn,0)) As Febrero	;
>>	....
>>	,	SUM(Iif(Month(fecped)=12,valpedmn,0)) As diciembre ;
>>Into Cursor (This.lcCursor) ReadWrite	;
>>From Pedidos ;
>>Inner Join Maepai On Pedidos.Codpai=Maepai.Codpai
>>Inner Join Maeven On Pedidos.codven=Maeven.codven ;
>>Where Pedidos.Fecped Between This.Cajafecha1.Value And This.Cajafecha2.Value;	&& replace This.Cajafecha1... and This.Cajafecha2 with variables
>>Group By Pedidos.Codpai,Pedidos.Codven	
>>
>Thanks Fabio, just one question why should I Change This.Cajafecha2.Value with a variable?

Rushmore optimzation is not good with properties.
Previous
Reply
Map
View

Click here to load this message in the networking platform