Using VFP9 SP2
I have the following SQL:
This gives me the GROUP BY CLAUSE is invalid error. Can someone suggest why that is?
I can run the above as
Thanks,
Stewart
I have the following SQL:
Code:
SELECT TOP 15 Claimed, SUM(Amount)*TaxRates.taxrate/TaxRates.GrossUp AS Total, {} AS FirstDate, {} AS LastDate ;
FROM Donation ;
JOIN TaxRates ON BETWEEN(DonDate, YearStart, YearEnd) ;
WHERE NOT EMPTY(claimed) ;
INTO CURSOR curTemp GROUP BY 1,3,4 ORDER BY 1 DESCENDING
This gives me the GROUP BY CLAUSE is invalid error. Can someone suggest why that is?
I can run the above as
Code:
SELECT TOP 15 Claimed, SUM(Amount)*[COLOR=red]22/78[/color] AS Total, {} AS FirstDate, {} AS LastDate ;
FROM Donation ;
JOIN TaxRates ON BETWEEN(DonDate, YearStart, YearEnd) ;
WHERE NOT EMPTY(claimed) ;
INTO CURSOR curTemp GROUP BY 1,3,4 ORDER BY 1 DESCENDING
Thanks,
Stewart