Setting OrderBy For Chart

Giganews Newsgroups
Subject: Setting OrderBy For Chart
Posted by:  Bob Darlington (b…@dpcmanAX.com.au)
Date: Fri, 25 Aug 2006

I have the following string for a RowSource for a chart which works fine,
except for the Sort Order for the legend. The legend appears in the Order of
Category (Alpha), but I want it in order of a field from the query
qsSumSalesCat  called 'SortOrder' (Numeric).

TRANSFORM SUM(qsSumSalesCat.[SalesRate]) AS [SalesRate] SELECT sDate FROM
qsSumSalesCat WHERE PropNum = 1 AND sDate BETWEEN #07 31 2005# AND #07 31
2006# AND Category <> 'Z'  GROUP BY sDate  PIVOT Category;

I've tried inserting SortOrder as shown below, but get an error 'Syntax
Error in Transform statement'.

TRANSFORM SUM(qsSumSalesCat.[SalesRate]) AS [SalesRate] SELECT sDate,
SortOrder FROM qsSumSalesCat WHERE PropNum = 1 AND sDate BETWEEN #07 31
2005# AND #07 31 2006# AND Category <> 'Z'  ORDER BY SortOrder GROUP BY
sDate  PIVOT Category;

Any help appreciated.

--
Bob Darlington
Brisbane

Replies