Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I have a table which is shown below :
Date | WorkingDate | Sales |
---|---|---|
1 | 1 | 100 |
2 | 10 | |
3 | 3 | |
4 | 2 | 300 |
5 | 3 | 500 |
6 | 4 | 900 |
I want to show the cumulative Sales by WorkingDate and the Sales of non-WorkingDate must be sumed to their nearest workingdate (the nearst workingdate must be greater than the non-workingdate). That's to say the sales of date 2 and date 3 will be sumed to workingdate 2.
The correct result table would like this :
Workingdate | CumulativeSales |
---|---|
1 | 100 |
2 | 413 |
3 | 913 |
4 | 1813 |
thanks.
Zhou
HI,
Use Workingdate as Dimension in Straight table and Sum(CumulativeSales) as expression and select
Full Accumulation option in Expression tab of Chart Properties.
Hope this helps you.
Regards,
Jagan.
Hi Jagan, Thanks for you prompt response. I did as you suggested while the result table is below: the non-workingdate's sales is been ignored.
From the script you can do it..
Data1:
Load
Date,
WorkingDate,
Sales
From
Data.xls
Data2:
Load
Date as Date2,
WorkingDate as WorkingDate2,
Sales as Sales2,
Sales + peek(Sales) as SalesAcum
Resident Data1
Order by Date asc;
If you need an specifc order like you load... could be...
Data1:
Load
Date,
WorkingDate,
Sales,
autonumber() as ID
From
Data.xls
Data2:
Load
Date as Date2,
WorkingDate as WorkingDate2,
Sales as Sales2,
Sales + peek(Sales) as SalesAcum,
ID
Resident Data1
Order by ID asc;
Hi,
Please find attached file for solution.
Regards,
Jagan.
How can i Attach it i dont know how...
Hi,
Click on Use Advance Editor option on top of the reply text box.
Regards,
Jagan.
Thank you Jagan, it works. But i choose to do it manually because of the complexity of my real data. Thanks.
Thanks for your help. I have worked it out as Jagan suggested. Your solution is the same as his.