Hi Geoff,
See
Re: Change in SQL commands! Message #
941774. The problem with you select is that yo didn't specify from wich record in a group values for i_key, and contractor should come. If they are the same for all records in a group, yopu can include them into GROUP BY clause. If you don't care from wich record those values comes, you can wrap those fields into MIN or MAX function. The solution depends on what result you want to get for those two fields.
>
>I am encountering "GROUP BY clause is missing or Invalid" errors using VFP9 (haven't tried VFP 8) in the following code.
>
>
>SELECT cnt(wo_itemno) as items, i_key, t_key, contractor ;
> FROM v_woitems ;
> INTO CURSOR tWoinvcont ;
> ORDER BY t_key ;
> GROUP BY t_key
>
>
>If I "SET ENGINEBEHAVIOR 70" the problem disappears.
>
>The same occurs when I create a query using the default SET ENGINEBEHAVIOR 90. It appears that this may be because I am doing a select on a view.
>
>Could someone point me to where I can find what has changed and how I create the same cursor using
>SET ENGINEBEHAVIOR 90.
--sb--