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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Best Way to Implement a Filter for non Calculations:

I am trying to establish a fund balance based off a combination of 3 digit funds.  My current formula is this:

 

Balance = CALCULATE( SUMX ('UtilityCheck',[CY-AMT]),'Accounts'[Full Code] = "10400-0") +
                   CALCULATE( SUMX('UtilityCheck',[CY-AMT]),Accounts[Full Code] = "10520-0") -
                    CALCULATE( SUMX('UtilityCheck',[CY-AMT]),Accounts[Full Code] = "10521-0") -
                      CALCULATE( SUMX('UtilityCheck',[CY-AMT]),Accounts[Full Code] = "10570-0") -
                         CALCULATE( SUMX('UtilityCheck',[CY-AMT]),Accounts[Full Code] = "10571-0")
 
And to filter the funds I want I put a slicer on my page and check "621" & "821" which is from the table Funds and column fund number.
 
My question is how can I write a comphrenisve formula to get rid of the slicer and make room for more?
Any help is much apprecaited!
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

You may try ALL function. It can ignore the filtering of the slicer.

For example,

vstephenmsft_0-1644309781370.png

Put the ID column in the slicer, then select B and C, my measure is to calculate the value of Full Code equal to 10400-0.

Measure = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),[Full Code]="10400-0"))

vstephenmsft_1-1644309855540.png

 

If you are still confused, please provide dummy data and expected results.

 

Best Regards,

Stephen Tao

 

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

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

 

You may try ALL function. It can ignore the filtering of the slicer.

For example,

vstephenmsft_0-1644309781370.png

Put the ID column in the slicer, then select B and C, my measure is to calculate the value of Full Code equal to 10400-0.

Measure = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),[Full Code]="10400-0"))

vstephenmsft_1-1644309855540.png

 

If you are still confused, please provide dummy data and expected results.

 

Best Regards,

Stephen Tao

 

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

amitchandak
Super User
Super User

@Anonymous , if you putting a slicer on table UtilityCheck or joined table, then that should work 

also you can simplify it

 

CALCULATE( SUM ('UtilityCheck',[CY-AMT]),filter('Accounts','Accounts'[Full Code] in{ "10400-0" ,"10520-0"))

- CALCULATE( SUM ('UtilityCheck',[CY-AMT]),filter('Accounts','Accounts'[Full Code] in{ "10521-0" ,"10570-0", "10571-0"))

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

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.