Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
I have the formula to calculate the percentage by category, the problem is that to show the %, the total values it's different for each category.
My chart use how dimension:
Master Item Dimension1: Month, Day
The measure is below, as for example category A
count(distinct
{<
Year= {$(vCY)},
Month = {$(vYTD)},
Category={"A"}
>} ID_Reclamacao)
/
count(distinct
{<
Year= {$(vCY)},
Month = {$(vYTD)},
Category={"*"}
>} ID_Reclamacao)
I have 8 categories, the values for each one are to January month:
A 26 335 | B 22 237 | C 16 731 | D 39 087 | E 11 761 | F 5 136 | G 1 936 | H 9283 |
The sum of all categories is: 132.506
The return values for Category={"*"} is 131.696 ( because I'm using count distinct )
How can do I do for the denominator to return the correct value 132.506? Its necessary aggr?
Hi,
I think something like this (not tested);
count(distinct
{<
Year= {$(vCY)},
Month = {$(vYTD)},
Category={"A"}
>} ID_Reclamacao)
/
sum(aggr(count(distinct
{<
Year= {$(vCY)},
Month = {$(vYTD)},
Category={"*"}
>} ID_Reclamacao),Category)
Cheers,
Chris.