Hi Chaim,
For example:
Select 1 As WhichQuery, <Other Fields> Group By <Group1 Expression> ;
UNION;
Select 2 As WhichQuery, <Other Fields> Group By <Group2 Expression>;
Into Cursor curSomeName
This will give you a single cursor containing the results of both queries. You can differentiate between the different queries by referring to the field WhichQuery.
As far as printing is concerned, you can enter the field WhichQuery into the Group Expression field in the Data Grouping dialog and tick "Start each group on a new page".
Is this what you mean?
Liam
>Thanks,Liam
>But I don't have prolem with the 'group by SQL statement'.
>I have the results in cursor.
>I have a problem to print the cursor grouped by different ways (if you use with form disiner wizard you can see the groups options in step 2 - I speak about this category).
>Chaim
Liam O'Hagan
MCP VFP Desktop Apps