On 7/18/12 10:36 AM, Kurt Wendt wrote:
> I'm getting this error - it claims that GROUP BY is Missing or Invalid.
> And, for the life of me - I don't see the problem. I've done Grouping
> before to Sum a particular column - so, just not sure why its not
> working this time around.
>
>
>
> The actual code is as follows:
>
> SELECT SHIPNO, PONO, Vendor, REFNO, REFDATE, ;
>
> Complete, sum(QTYTOT) as Received ;
>
> FROM Ship_Ln_Cursor ;
>
> INTO CURSOR Shipment_Lines_List ;
>
> GROUP BY SHIPNO, pono
I'm not sure about VFP, but I do know that standard SQL requires explicit
grouping by
all but the aggregate fields. So:
select shipno,
pono,
vendor,
refno,
refdate,
complete,
sum(qtytot) as received
from ship_ln_cursor
into cursor shipment_lines_list
group by 1,2,3,4,5,6
Oops I forgot the semicolons but you get the idea.
Paul
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message:
http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the
author, and do not constitute legal or medical advice. This statement is added
to the messages for those lawyers who are too stupid to see the obvious.