Hello,
This is a basic query in excel and also sql. I am building a report from an oracle table that is split as follows:
| |
Total |
Sales |
| Jan |
$ 543.00 |
22 |
| Feb |
$0 |
0 |
| March |
$ 654.00 |
3 |
| April |
$ 456.00 |
4 |
I have created a bar grapgh in a subreport in crystal that will split by month. Basically I am looking to have the Total / Sales for each month in the graph.
Unfortunately, it seems that crystal is having trouble processing this request since I don't know the exact formula.
In SQL, it would be:
SELECT MONTH, (TOTAL / SALES) As AvgSales
FROM TABLE
GROUP BY 1
.. but I am having endless issues getting this across in crystal.
The main problem is the number of drill downs, since those months and values appear frequently. It seems that Crystal grabs the average of each month, rather than summing the sales buy the month/drill down ,summing the trans by the month/drill down and then dividing each from each other.
I would greatly appreciate any assistance since I have been struggling with this for weeks.