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! Learn more

Reply

Trouble setting my filter in a simple division formula

I currently have this as a calculated measure in power BI: 

% of Distinguished = DIVIDE(SUMX(Sheet2, Sheet2[# of Distinguished]), COUNT(Sheet2[# of Pack Rec]))

 

This works well, however I realize now that this "# of pack Rec" column has 0s that I want to exclude from this division (# of pack rec is either 1 or 0). How do I filter out the zeros in calculated measure?

 

 

1 ACCEPTED SOLUTION
parry2k
Super User
Super User

@daniel_krantz_4 try this:

 

 CALCULATE ( COUNT(Sheet2[# of Pack Rec], Sheet2[# of Pack Rec] = 1 )


Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

View solution in original post

3 REPLIES 3
parry2k
Super User
Super User

@daniel_krantz_4 this is what your full measure will look like, we are changing denominator

 

% of Distinguished = DIVIDE(SUMX(Sheet2, Sheet2[# of Distinguished]),  CALCULATE ( COUNT(Sheet2[# of Pack Rec], Sheet2[# of Pack Rec] = 1 ))


Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

parry2k
Super User
Super User

@daniel_krantz_4 try this:

 

 CALCULATE ( COUNT(Sheet2[# of Pack Rec], Sheet2[# of Pack Rec] = 1 )


Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

What you are showing here - is that meant to be the denominator of the formula? I'm not quite sure how to plug that in to the broader formula
The Numerator is good and doesn't need adjusted: DIVIDE(SUMX(Sheet2, Sheet2[# of Distinguished]), 

The Denominator is where I am having my issues. But when I add in your addition I get errors 

 

Helpful resources

Announcements
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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 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.

Top Solution Authors