Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hello,
Can anyone help me to get the total sales per week(dimension) from the table below;
WeekNumber | Channel | Sales | Column that should return total of the week(Expected Results) |
1 | abc | 0 | 20 |
1 | asd | 20 | 30 |
2 | asd | 30 | 30 |
3 | sdgfds | 40 | 220 |
3 | sdfsd | 50 | 220 |
3 | bddvbv | 60 | 220 |
3 | lokpko | 70 | 220 |
The idea is to have the repartition of the sales per week and per Channel. I used Aggr as shown below but the results are as follows:
Formula: sum(aggr(sum(sales),WeekNumber))
WeekNumber | Channel | Sales | Column that should return total of the week(Expected Result) | Used Aggr from QV |
1 | abc | 0 | 30 | 30 |
1 | asd | 20 | 30 | 0 |
2 | asd | 30 | 30 | 30 |
3 | sdgfds | 40 | 220 | 220 |
3 | sdfsd | 50 | 220 | 0 |
3 | bddvbv | 60 | 220 | 0 |
3 | lokpko | 70 | 220 | 0 |
Thanks in advance,
Selen
Try:
sum(total <WeekNumber> sales)
Hope this helps!
try like these
sum(total sales)/Weeknumber
or
div(aggr(sum(total sales)),Weeknumber)
Hi,
use this expression
Aggr(sum(DISTINCT Sales),WeekNumber)
Hope this helps
Thanks & Regards
did you mean week or week and channel?
sum(total <WeekNumber> sales)
sum(total <WeekNumber, Channel> sales)