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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
MuppetyMe
Helper I
Helper I

Help with Multiple Text Filters

Needing assistance with an expression to filter multiple text options. For example: 

 

Starts with Text A -or-

Starts with Text B -or-

Starts with Text C -or-

Starts with Text D

 

Is this even possible? Any suggestions? There are too many variables in the data source to use basic filtering as all of the above have additional words in the titles. 

1 ACCEPTED SOLUTION
MuppetyMe
Helper I
Helper I

4/9/21 Update: SOLVED!

 

Received a brilliant suggestion that resolved my issue: "you should be able to use the filters pane. By default it only shows two options but you can first select 4 random [data points] from the Basic filtering and then switch to Advanced to get more filter criteria.

https://community.powerbi.com/t5/Service/Advanced-Filter/td-p/3834

 

Advanced Filter PBI.png

View solution in original post

11 REPLIES 11
MuppetyMe
Helper I
Helper I

4/9/21 Update: SOLVED!

 

Received a brilliant suggestion that resolved my issue: "you should be able to use the filters pane. By default it only shows two options but you can first select 4 random [data points] from the Basic filtering and then switch to Advanced to get more filter criteria.

https://community.powerbi.com/t5/Service/Advanced-Filter/td-p/3834

 

Advanced Filter PBI.png

Anonymous
Not applicable

@MuppetyMe 

 

It would really help if you could put parentheses in the right places. Currently, one doesn't know if OR binds stronger than AND or the other way round.

Sorry friend, novice PBI user 🙂

ERD
Community Champion
Community Champion

Hello @MuppetyMe ,

If the text starts from A/B/C/D it already cannot start with E/F, so the second part of your expression is not clear to me.

In case of measure:

FirstLettersCheck = 
IF(LEFT(SELECTEDVALUE(T[Column]),1) IN {"A","B","C", "D"},1,0)

 

Did I answer your question? Mark my post as a solution! 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Appreciate your Kudos.

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

ALSO @ERD, you are correct in your logic that if the text starts from A/B/C/D it already cannot start with E/F -- so thank you for that 🙂

Hello @ERD, thank you for the solution. Unfortunately this method does not work either... according to MS articles, "SELECTEDVALUE" does not work if the data source is a direct query. I'm frustrated because it feels like I'm super close to a solution with this suggestion, but it doesn't work. 

ERD
Community Champion
Community Champion

@MuppetyMe , 

Try to use "MAX" instead of "SELECTEDVALUE"

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Appreciate your Kudos.

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

amitchandak
Super User
Super User

@MuppetyMe , you can create a new column like

 

if( left([Column],1) in {"A","B","C", "D"} && not(left([Column],1) in {"E","F"} ) , true(), false())

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak, thank you for the solution. Unfortunately the data admins have the source locked down in a manner that I'm unable to create columns (this is an SSAS cube). To the best of my knowledge I'm limited to measures and basic/advanced filters.

Anonymous
Not applicable

@MuppetyMe 

 

What about composite models where you can mix data from remote sources and local data? Would that not solve your problem? If you don't know what composite models are... Use composite models in Power BI Desktop - Power BI | Microsoft Docs

Hi @Anonymous, thank you for the response. I believe your solution would be appropriate if I were able to mix data sources, but currently I am not able to do so due to the way the admins have the SSAS cube established + the fact I'm using direct query.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.