Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear all,
I would like to create a graph that shows the amount of order per customer_id and also show the sum of the orders.
For this I have the following dataset:
LOAD * INLINE [
Employee_ID, Customer_id, Order_id, Order_total
1, 11, 6, 12
2, 12, 7, 14
3, 13, 8, 176
4, 14, 9, 12
5, 15, 10, 8
];
With this data I try to create a bar-chart with the following details:
- An calculated dimension: =Aggr(Count([Order_id]), [Customer_id])
- An expresiion: =Aggr(Sum([Order_total]), [Employee_ID])
When I look at the graph however no data shows up. Any thoughts on what I am doing wrong here?
HI,
You can try just Sum([Order_total]) as an expression.
If that doesnt work then tell us What output you are expecting from the sample data.
Regards,
Kaushik Solanki
you should create bar chart having customer id as dimension and two expression as below:
Expr1: Count([Order_id])
Expr2: Sum([Order_total])
Hi
Not sure why you are using calculated dimension. It's always better to avoid these where possible as they have a negative effect on performance. Can you share you're expected output?
add Customer id as dimension and expression as Order amount
I think I agree with meghaagr, is there a reason you are not doing this?
It was just for training purposes as I wanted to get a better understanding of the calculated dimension topic...