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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
sqldev2017
Microsoft Employee
Microsoft Employee

Get Count based on condition or filter

I have a calculared measure - say  "Revenue".

 

I have a dimension called Accounts, which contains Unique AccountID.

 

The "Revenue" measure relates to the Accounts - Revenue for an account / Quarter/ Region.

 

I want to create a new Column using DAX ,  which returns DISTINCT Count of all Accounts  where "Revenue" > 500000 

 

Bear in mind that , this "Revenue" , is a calculated Measure.

 

Thank You,

1 ACCEPTED SOLUTION

 Thank you for your replies.

 

I think I found the solution in a different POWERBI thread - 

 

CALCULATE(DISTINCTCOUNT(Sales[Sales_ID]),FILTER(VALUES(Sales[Sales_ID]),[YTDSales]>3000))

View solution in original post

3 REPLIES 3
PattemManohar
Community Champion
Community Champion

@sqldev2017 Please post the sample data in copiable format, which will be helpful to suggest any accurate solution.





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

Proud to be a PBI Community Champion




LivioLanzo
Solution Sage
Solution Sage

Hi @sqldev2017

 

are you able to post a sample of your data?

 

thx

 


 


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


Proud to be a Datanaut!  

 Thank you for your replies.

 

I think I found the solution in a different POWERBI thread - 

 

CALCULATE(DISTINCTCOUNT(Sales[Sales_ID]),FILTER(VALUES(Sales[Sales_ID]),[YTDSales]>3000))

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.