Hi,
We have a scenario in HANA modelling where we are calculating No. of days by dividing (Current Inventory value divide by Last 3 months Sales) * 91. Can some one help in getting this output from a calculation view. The data in the cube is by Month and Year.
| Calmonth | CalYear | Inventory | Sales |
|---|---|---|---|
| 10 | 2014 | 98 | 1111 |
| 11 | 2014 | 97 | 1212 |
| 12 | 2014 | 96 | 1213 |
| 1 | 2015 | 100 | 1000 |
| 2 | 2015 | 123 | 1100 |
| 3 | 2015 | 133 | 1240 |
| 4 | 2015 | 132 | 1320 |
| 5 | 2015 | 124 | 1430 |
| 6 | 2015 | 154 | 1540 |
I would like to get these results as output of the calculation view.
| Calmonth | CalYear | No.ofDays |
|---|---|---|
| 1 | 2015 | =100*91/(1000+1213+1212) |
| 2 | 2015 | =123 *91/(1100+1000+1213) |
| 3 | 2015 | =133 *91/(1240+1100+1000) |
| 4 | 2015 | =132 *91/(1320+1240+1100) |
| 5 | 2015 | =124 *91/(1430+1320+1240 |