Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
i am new using QlikSense and I have a problem in calculating a ratio.
I need to calculate the ratio by dividing each voice of Account Balance By revenue that in this case is highlighted in yellow.
So i need to do : -16-487.675,09/ 30.833.658,42 or -2.125.011,63/30.833.658,42 end so on.
Now my measure is like this but i can't fix the voce of revenue as denominator:
num( (sum (if ( [Anno Fiscale] = $(vAnnoFiscale),[Valore]))
/
(sum (if ([Voce Conto Economico]= 'A' and [Anno Fiscale] = $(vAnnoFiscale),[Valore])))),
'%#.##0,0')
Where [Voce Conto Economico] is the voce of the account Balance and 'A' is the Revenue.
Thank you,
Isabela
give a try with:
sum( {< [Anno Fiscale] = {"$(vAnnoFiscale)"} >} Valore )
/
sum( {< [Anno Fiscale] = {"$(vAnnoFiscale)"}, [Voce Conto Economico] = {"A"} >} Valore )
It Gives me the same mistake like in the screenshot.
which chart object, dimensions and measures are you using ?
I want to calculate the RATIO AMOUNT. With the numers from the table i need to do : -16-487.675,09/ 30.833.658,42 or -2.125.011,63/30.833.658,42 end so on but i have only "1" in case of the Revenue and that is ok but instead of the others ratio i have "-" that because i have the Revenue and so the denominator = 0.
I suggest you to post a sample app with the desired result.
Ratio = sum(Actual Amount)/ sum({<Voce Conto Economico={'Totale Ricavi Di Commessa'}>}Actual Amount)