Stephen - you're probably right. When I first developed the code - and was 
constantly looking at the data to make sure things matched up right - I 
actually gathered up more fields than I really needed. 

Based upon looking at my code again now - I see I really only need:
        PPitem, ShpTot, store

I'm surprised that ALL the fields must now be included in the GROUP BY 
specification. But, maybe this may ALSO have something to do with Matthew's 
response. I'm going to look into his suggestion to see how it may apply to my 
situation. 

Thanks for the Input!
-K-

-----Original Message-----
From: [email protected] [mailto:[email protected]] On 
Behalf Of Stephen Russell
Sent: Friday, May 07, 2010 5:03 PM

On Fri, May 7, 2010 at 3:43 PM, Kurt Wendt <[email protected]> wrote:
> ...and, yet - the SAME Query would work FINE under VFP7. And, it's
> driving me NUTS that I can't figure out WHY!
>
> This is the Select Statement:
>        SELECT  invoice, store, style, color, PPitem, ;
>                        LineGroups, Sum(ShpTot) AS ShpTot ;
>                From &CurrTmpFile.  ;
>                Where !EMPTY(AstFlag)  ;
>                Group By Store, PPitem  ;
>                Into Cursor InvLn_Sums
> The Error message I get is the following:
>         SQL: GROUP BY clause is missing or invalid.
-------------------------
SELECT  invoice, store, style, color, PPitem, ;
                        LineGroups, Sum(ShpTot) AS ShpTot ;
                From &CurrTmpFile.  ;
                Where !EMPTY(AstFlag)  ;
                Group By invoice, store, style, color, PPitem, ;
                        LineGroups ;
                Into Cursor InvLn_Sums

Do you really need an invoice #  to total on?
-- 
Stephen Russell

_______________________________________________
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/289ea162f5642645b5cf64d624c66a14071a1...@us-ny-mail-002.waitex.net
** 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.

Reply via email to