Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Currently, I am calculating the Inventory cover like below:
Now, I need to calculate the Inventory cover contribution.
((Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Production Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Blocked Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock in Transit])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock at Quality])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Total Valuated Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Unrestricted Stock]))
/
RangeAvg(sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate))$(=Date(vMaxSalesDate-6))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-7))>=$(=Date(vMaxSalesDate-13))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-14))>=$(=Date(vMaxSalesDate-20))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-21))>=$(=Date(vMaxSalesDate-28))"},[Sales Volume]={">=0"}>}[Sales Volume])))*6.5
Can you please let me know if have any solutions for this.
Required Table:
Product Group | Product Code | Inventory Cover in days | % |
A | 1 | 6 | 11.32% |
A | 2 | 5 | 9.43% |
A | 3 | 4 | 7.55% |
B | 4 | 5 | 9.43% |
B | 5 | 6 | 11.32% |
C | 6 | 6 | 11.32% |
D | 7 | 10 | 18.87% |
E | 8 | 11 | 20.75% |
% = Inventory Cover in Days/ Total Inventory Cover in days
(((Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Production Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Blocked Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock in Transit])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock at Quality])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Total Valuated Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Unrestricted Stock]))
/
RangeAvg(sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate))$(=Date(vMaxSalesDate-6))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-7))>=$(=Date(vMaxSalesDate-13))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-14))>=$(=Date(vMaxSalesDate-20))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-21))>=$(=Date(vMaxSalesDate-28))"},[Sales Volume]={">=0"}>}[Sales Volume])))*6.5)
/
Sum(Total RangeSum(Aggr(
((Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Production Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Blocked Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock in Transit])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock at Quality])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Total Valuated Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Unrestricted Stock]))
/
RangeAvg(sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate))$(=Date(vMaxSalesDate-6))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-7))>=$(=Date(vMaxSalesDate-13))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-14))>=$(=Date(vMaxSalesDate-20))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-21))>=$(=Date(vMaxSalesDate-28))"},[Sales Volume]={">=0"}>}[Sales Volume])))*6.5,[Product Code])))
Use Total qualifier to get Total inventory cover (perform an aggregation across all dimensions)
Can you please give me an expression for this.
Thanks for your helping hand.
It could be like this:
Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])
/
Sum(TOTAL {$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])
Add your remaining expressions into this.
Thanks for your help.
I got the answer.
(((Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Production Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Blocked Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock in Transit])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock at Quality])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Total Valuated Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Unrestricted Stock]))
/
RangeAvg(sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate))$(=Date(vMaxSalesDate-6))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-7))>=$(=Date(vMaxSalesDate-13))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-14))>=$(=Date(vMaxSalesDate-20))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-21))>=$(=Date(vMaxSalesDate-28))"},[Sales Volume]={">=0"}>}[Sales Volume])))*6.5)
/
Sum(Total RangeSum(Aggr(
((Sum({$<[Transaction Date]={"$(vMaxDepotDate)"}>}[Depot Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Production Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Blocked Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock in Transit])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Stock at Quality])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Total Valuated Stock])+
Sum({$<[Transaction Date]={"$(vMaxProductionDate)"}>}[Unrestricted Stock]))
/
RangeAvg(sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate))$(=Date(vMaxSalesDate-6))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-7))>=$(=Date(vMaxSalesDate-13))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-14))>=$(=Date(vMaxSalesDate-20))"},[Sales Volume]={">=0"}>}[Sales Volume]),
sum({$<[Transaction Date]={"<=$(=Date(vMaxSalesDate-21))>=$(=Date(vMaxSalesDate-28))"},[Sales Volume]={">=0"}>}[Sales Volume])))*6.5,[Product Code])))