Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
ivanaksen
Contributor III
Contributor III

Multiple Criteria in Sum expression

Hello everybody,

Please support with the bellow issue:

in Visualization I need to see percentage of data  with the condition Aging> than 89 days, and I have the formula, which is not correct working, it`s showing only 1, like I dont have filter [Aging]={'>89'}:

sum({<[Aging]={'>89'}>}Amount.Loc)/Sum([Amount.Loc])

But all data is in Raw data table is correct with aging.

I tried to make the formula in script: sum(If(Aging>89,([Amount.Loc]))) as Aging_delay_Amount,

but again I have an error there.

please advise

1 Solution

Accepted Solutions
sunny_talwar

How about if you try this with double quotes?

Sum({<[Aging] = {">89"}>} [Amount.Loc])/Sum([Amount.Loc])

View solution in original post

4 Replies
sunny_talwar

How about if you try this with double quotes?

Sum({<[Aging] = {">89"}>} [Amount.Loc])/Sum([Amount.Loc])

ivanaksen
Contributor III
Contributor III
Author

Thanks a lot, finaly it works

sasiparupudi1
Master III
Master III

May be change your script expressi to aflag


sum(If(Aging>89,([Amount.Loc]))) as Aging_delay_Amount,

to

If(Aging>89,1,0)) as Aging_delay_flag


in the chart

Sum({<[Aging_delay_flag] = {1}>} [Amount.Loc])


btw, did you check if your field value a number or a string?

ivanaksen
Contributor III
Contributor III
Author

This works good, too thank you