Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How can I filter an object using data handling

Hi,

I have done quite some research on this but not found an adequate answer, yet.

I have a simple sum function for a KPI. On different Sheets, I use the same KPI but want to apply different filter.

The KPI is simply total revenue generated.

One one sheet, I want the full sum over all data.

On another sheet, I want to limit it to last month, only. I realize I can do this with measures, but I want to avoid duplicating a whole load of measures. I rather want to use the same measures and apply the condition in the "Add-Ons" -> "Data handling" -> "Calculation Condition".

I feel this should be possible, but I have not found a formula yet which filters accordingly.

So far, I have tried the following entries in that field (simplified to fixed month).

IF(month=8,1,0)

or

month=8

Neither of this works so I am currently out of ideas. Can anyone help?

Michael !

2 Replies
JonnyPoole
Employee
Employee

The calculation condition is a boolean condition to render the object or not, not a filter for the rows to be included in the KPI aggregation unfortunately.

The only element that can provide a filter on the KPI is the measure itself (as you say) or the selection state on the app as a whole.

rortiz
Contributor
Contributor

Hi there, i use a line in the  "Expression" box  on the "Measures" at the right of the edit screen.

Usually says

sum(field)

but i use:

sum({$<month-={'june'}>} month)

where month is the field

june is the subject of the field

-= means distinct

This will sum every "month" on month, except the "july" month.

I hope it is usefull