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
TonyAshton
Frequent Visitor

DAX help requied

I need help with creating a measure for the percentage of products with more than 1000 sales.

 

The table I have is called products which is a list of sales with each row a unique sale. Within this table I have a column called Product Name.

 

I have created a measure for total sales which is the count of site product name. But the measure I need is a little beyond me at the moment.

As I can’t work out in the one measure how to combine the following. 
1. Number of PRODUCTS
2. Number of SALES per PRODUCT
3. Number of PRODUCTS with more than 1000 SALES 
4. % of PRODUCTS with more than 1000 SALES

1 ACCEPTED SOLUTION
FreemanZ
Super User
Super User

hi @TonyAshton 

try like:

BestProduct% =
VAR _allrproduct = 
COUNTROWS(ALL(TableName[Product Name]))
VAR _bestproduct =
COUNTROWS(
    FILTER(
        VALUES(TableName[Product Name]),
        CALCULATE(COUNTROWS(TableName))>=1000
    )
)
RETURN
DIVIDE(_bestproduct, _allrproduct)

View solution in original post

2 REPLIES 2
TonyAshton
Frequent Visitor

Thank you. This works great.

FreemanZ
Super User
Super User

hi @TonyAshton 

try like:

BestProduct% =
VAR _allrproduct = 
COUNTROWS(ALL(TableName[Product Name]))
VAR _bestproduct =
COUNTROWS(
    FILTER(
        VALUES(TableName[Product Name]),
        CALCULATE(COUNTROWS(TableName))>=1000
    )
)
RETURN
DIVIDE(_bestproduct, _allrproduct)

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.