Forum Discussion
Show active filters.
- Anonymous8 years ago
Ok... I achieved a solution... it is not very orthodox but it works fine... Very tedious to write...
It consists in a Measure of more than 120 lines (because the big number of columns and tables) with a text result that I can insert into a Card visualization or a table for better viewing.
The approximate formula syntax of the measure is like this:
_Active filters_ = "FilterSubsection:" &IF(ISFILTERED(Table1[Column1]); UNICHAR(10)&"- StringColumnName: "& CONCATENATEX(VALUES(Table1[Column1]);Table1[Column1];", ")) &IF(ISFILTERED(Table1[Column2]) ... (etc)Where u see Table1 you can refer to Table2, Table3 an so on.
UNICHAR(10) is a newline character and & simbol is to concatenate strings.
Hope this serves to someone in the future and really hope that the PBI team include a feature to achieve this easier.
Thanks.
Ok... I achieved a solution... it is not very orthodox but it works fine... Very tedious to write...
It consists in a Measure of more than 120 lines (because the big number of columns and tables) with a text result that I can insert into a Card visualization or a table for better viewing.
The approximate formula syntax of the measure is like this:
_Active filters_ =
"FilterSubsection:"
&IF(ISFILTERED(Table1[Column1]);
UNICHAR(10)&"- StringColumnName: "& CONCATENATEX(VALUES(Table1[Column1]);Table1[Column1];", "))
&IF(ISFILTERED(Table1[Column2])
... (etc)Where u see Table1 you can refer to Table2, Table3 an so on.
UNICHAR(10) is a newline character and & simbol is to concatenate strings.
Hope this serves to someone in the future and really hope that the PBI team include a feature to achieve this easier.
Thanks.
- Anonymous8 years agoNot applicable
First of all, thanks for the amazing post, it was really usefull for me.
Although it works perfectly when i applied the sintax:
Filter activ =
"Filter active:"
&IF(ISFILTERED(event[Sex])
;UNICHAR(10)&"Sex: "& CONCATENATEX(VALUES(event[Sex]);event[Sex];", "))
&IF(ISFILTERED(event[age])
;UNICHAR(10)&"Ages: "& CONCATENATEX(VALUES(event[age]);event[age];", "))
&IF(ISFILTERED(eventoysujeto[Date])
;UNICHAR(10)&"Date: "& CONCATENATEX(VALUES(event[Date]);eventoysujeto[Date];", "))It shows me something (perfect) like:
Filter active:
Sex: Male.
Age: 85, 88, 73, 55, 80, 73, 89, 72, [...] and so on.
Date: 4/3/2017, 2/21/2018 [...] and so on.
My problem is that i do have dozens of different ages and dates. I do want to obtain something like this:
Filter active:
Sex: Male.
Age min: 56
Age max: 90
fDate: 4/3/2017
lDate: 12/31/2017
Or if possible:
Filter active:
Sex: Male.
Age: 56 to 90.
Date: 4/3/2017 to 12/31/2017.
May someone help me?
Thanks a lot,
Angel
- Anonymous8 years agoNot applicable
Anonymous For that, you can do something like this:
[...] &IF(ISFILTERED(event[age]) ;UNICHAR(10)&"Ages: "& MIN(event[age]) & " - " & MAX(event[age]);", ")) [...]
Tell me if this is what you are looking for.
Regards.
- Anonymous7 years agoNot applicable
Anonymous Thanks a lot for the fast response and sorry for the dealy but i was out of office.
I did tried hundreds of changes before i post this, your sentence "should" do exactly what i am looking for but it does not work, it seems to appears and error with & I have tried, just with MIN, or with MAX, with less text, with more parenthesis and hundreds of combinations, but it does not work, i am out of ideas. If you have any i would love to hear them.
Thanks in advance,
Angel
- Bruno_Cippitell8 years agoRegular Visitor
Thank you very much for sharing.
It works perfect and I have to say: it is not that tedious and simply to achieve.
Two days ago a customer asked me to have "Active filter" text solution on a report and this solution fits perfectly. Thaks you one more time.
- Bruno_Cippitell8 years agoRegular Visitor
Thak you very much for sharing. It works perfect and I have to say: it is not that tedious and simply to achieve.
Two days ago a customer ask to have "Active filter" text solution and this solution fits perfectly. Thaks one more time.
- bolabuga5 years agoHelper V
Anonymous
Thks, it is still helping after all this time!!!