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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Lewis825
Regular Visitor

Count 0 Values in Table

I have a table with a list of all Accounts & their sales 

 

I need to flag all Accounts what have 0 sales 

 

My Sales Measure is;

var TYQTY = [TY Qty] return

IF(ISBLANK(TYQTY),0,TYQTY)

TY QTY being a simple sum measure - but returns blanks not 0's

 

My current Has No Sales measure is;

CALCULATE(DISTINCTCOUNT('Sale Data'[Account No.]),FILTER('Sale Data',[Store TY Qty]=0))

I have tried both Count & DistinctCount - both return the same result - below

Lewis825_1-1636470966474.png

This is counting an account with £14 sales and not flagging those with £0

however this doesnt count the bottom £24 value? 

 

Please advise  

 

2 REPLIES 2
Anonymous
Not applicable

Hi @Lewis825,

Can you please share a pbix or some dummy data that keep raw data structure with expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

Regards,

Xiaoxin Sheng

vanessafvg
Super User
Super User

if it's in the same table then you can just go,  but this might be too simple to understand this issue.  Can you share the actual data you using in text format?  Including the columns you are using to derive your measures

 

CALCULATE(DISTINCTCOUNT('Sale Data'[Account No.]) , sales = 0)





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors
Top Kudoed Authors