Filtering with Select Expression on multiple categories

149 viewsFormulas and Functions


I have a tableview on a canvas which I would like to filter with a filterbox created in another table which contains multiple selections. In a normal matrix I would use the Using As function to address the individual selections to the categories but to filter with an expression I need to use the Select function. The case now is I want to do multiple selections in 1 and I don’t know how to write the Select formula for this. So how to address 2 selections to 2 categories all in 1 formula.

Thanks Robert

Gilbert Answered question February 28, 2024

Hi Robert,

I always use Select, as it seems the most powerful to me.

Select statement has different syntaxes. The most simple one for me is (as I can use it always):

select ( source ,

and/or  (  condition 1,

condition2 , …



Having a SourceMatrix with Revenues Region x Year, this formula will bring you the value from the globals selector

:= select (SourceMatrix:: ,
and ( @SourceMatrix::Year:(Region) = Globals::YearSelector ,
@SourceMatrix::Region:(Year) = Globals::RegionSelector)

The difficult bit to understand is “:(Region)” – this means, you repeat all the values of the Year along Region (10 years times 4 regions, to get a year-value for the entire matrix of 40 values, and not only 10. Ifnot you have a #size error. The (Region) means that you expand along the 4 Region-items, but do not use them in the compare string.

See the example attached. Does this help?

Hope I understood well you question. Ifnot, it helps if you make a very simple model showing what you want to do, so we can directly work in your example.

Regards, Gilbert

Gilbert Edited answer February 28, 2024
You are viewing 1 out of 1 answers, click here to view all answers.

Latest Questions