Forum Discussion
Multi-Select filtering column checking if it contains multiple pieces of text
Hi morgtd30
(1)Create a table with selection “Apples”,” Oranges”,” Grapes”,” Bananas”.
(2)Add a slicer with [Slicer] .And then create a measure to return the string of select value .
Measure 2 = CALCULATE(CONCATENATEX(VALUES(Slicer[Slicer]),Slicer[Slicer],"; "))
(3)Create a measure to judge whether the Measure 2 in the column [Text] .If yes ,return 1 , otherwise return 0 .
CONTAINSSTRING = IF(CONTAINSSTRING(SELECTEDVALUE('Table'[Text]),Slicer[Measure 2]),1,0)
(4)Put the CONTAINSSTRING measure in visual filter and set CONTAINSSTRING is equal to 1 .The final result is as shown :
I have attached my pbix file , you can refer to it .
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Anonymous ,
Do you realize that your solution makes that if the order of the words are different then it does not return any result?
I have added a line with different values and the result is below:
Has you can see in your solution you are missing one line.
This is happening because using the CONCANATEX you are forcing the order of the text using my solution since I'm looking at individual words it shows the result: