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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
MAP
Frequent Visitor

Zero counts

I have stock exchange data in power bi.i have a measure that calculates whether closing price is maximum or not.if closing price is maximum this measure gives to the answer equall to zero.Now I want to count those zero in a separate measures

1 ACCEPTED SOLUTION
RossEdwards
Solution Sage
Solution Sage

You could do this using SUMX and VALUES.  First you'll need to understand what groupings will let you check a zero for.  Maybe its a particular stockcode.  Here is an example:

Zero Count = SUMX(
    VALUES('Stocks'[Stock Code]),
    IF([Closing price max check] = 0, 1, 0)
)

View solution in original post

2 REPLIES 2
MAP
Frequent Visitor

Thank You Sir

RossEdwards
Solution Sage
Solution Sage

You could do this using SUMX and VALUES.  First you'll need to understand what groupings will let you check a zero for.  Maybe its a particular stockcode.  Here is an example:

Zero Count = SUMX(
    VALUES('Stocks'[Stock Code]),
    IF([Closing price max check] = 0, 1, 0)
)

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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