This content has been marked as final. Show 3 replies
I am not sure if the anychart is doing the sorting. But i am also very new to apex and charts.
Try to sort the query-result in the way you want with order by testdate.
If it does not work you can change your query:
so you will get 201201, 201202, 201203, ... so it can be sorted.
Hi Thorsten,1 person found this helpful
You might find it useful to refer to the 'Sample Database Application', which gets installed in your workspace as part of a workspace provisioning. Edit the application, and view the chart series query for the 'Sales by Category/Month' chart on pg 5, where you'll see how the representation of the DATE information has been handled, which uses the following query:
You may want to try something similar in your query. Try it out in SQL Developer or SQL Workshop first, to verify the order of results.
select null, to_char(o.order_timestamp, 'MON RRRR') label, sum (decode(p.category,'Accessories',oi.quantity * oi.unit_price,0)) "Accessories" from demo_product_info p, demo_order_items oi, demo_orders o where oi.product_id = p.product_id and o.order_id = oi.order_id group by to_char(o.order_timestamp, 'MON RRRR'), to_char(o.order_timestamp, 'RRRR MM') order by to_char(o.order_timestamp, 'RRRR MM')
BTW is it safe to assume that your other open thread has now been answered: Re: Select x-axis into chart ?
this one works.
Edited by: Thorsten on 29.04.2013 00:59