Trust me, maybe you don't think so now, but down the road you should see benefits from accepting this. As you won't have to think about which tool you're writing the SQL in.
>>VFP syntax was finally changed in VFP8 to be more SQL standard compliant. In particular this affected the SQL "Group By" clause.
>>
>>In simple terms every column in your column list when using a Group By must fall into one of 2 categories:
>>
>>- the column must be part of an agregate, SUM, MAX, MIN, etc.
>>- the column must be part of the "Group By..." column list.
>>
>>To be SQL standard compliant, you must write your SQL Selects in this fashion.
>>
>>
>>>In the old days (VFP 7) I did the occasional GROUP BY and things went well. It was ... well it seemed intuitive.
>>>
>>>With VFP 9, the rules have changed, and no matter how many time I read what I can find in the help files, everything seems inside out now. I seem to end up with a GROUP BY clause that needs about 15 fields listed (none of which I want to group by).
>>>
>>>Can someone point me to an article of some sort that will fix this mental block that I have on the philosophy of GROUP BY? I'm getting really tired of "SQL: GROUP BY clause is missing or invalid".
>>>
>>>Bob
>
>Thanks to all.
>I think it was just the long list in the GROUP BY that was getting me down. I'll get over it.
>
>Bob
(On an infant's shirt): Already smarter than Bush