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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Filter issue with &&

Hi,
I have a trouble with filtering a table. Please see code below:
Screenshot_1.png
All Site[SiteCode] filters works properly, but not the Employee [DprtId] filter. This is what I see as the result:
Screenshot_2.png
Please help to understand what's wrong here. 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Thanks for turning me to the right track of thougts 🙂 Just needed to change && --> AND function and now it works as I expected. Posting screenshot to anyone can help in the future. 

Screenshot_1.png

 

View solution in original post

4 REPLIES 4
Greg_Deckler
Community Champion
Community Champion

Extremely difficult to say without sample source data. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

 

But, perhaps you meant that their DeptId = 100 && ( RELATED || RELATED || RELATED || RELATED )  ?



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Thanks for turning me to the right track of thougts 🙂 Just needed to change && --> AND function and now it works as I expected. Posting screenshot to anyone can help in the future. 

Screenshot_1.png

 
az38
Community Champion
Community Champion

Hi @Anonymous 

First of all, your OR conditions should be in parenthesises like

[DrtID] = 100 && ([SiteCode]="OD" || [SiteCode]="KV" || [SiteCode]="LV")

 


do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn
Anonymous
Not applicable

@az38  Hi! I can't do like that because of RELATED function

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors