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
netanel
Post Prodigy
Post Prodigy

AVG Problem

Hey All!

 

This is my measure:

Net USD average per Day =
AVERAGEX(
    KEEPFILTERS(VALUES('Date'[Date])),
    CALCULATE(SUM('Revenues DB'[Net USD]))
)
 
I can not reach the exact amount
I think it's because the formula also calculates BLANK
How do I ignore BLANK in such a formula like this?







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

Connect on Linkedin
linkedin.com/in/netanel-shriki
1 ACCEPTED SOLUTION
AlexisOlson
Super User
Super User

If that is the problem, then you could try this:

Net USD average per Day =
VAR NetPerDay =
    ADDCOLUMNS (
        VALUES ( 'Date'[Date] ),
        "Net", CALCULATE ( SUM ( 'Revenues DB'[Net USD] ) )
    )
RETURN
    AVERAGEX ( FILTER ( NetPerDay, NOT ( ISBLANK ( [Net] ) ) ), [Net] )

 

I'm pretty sure AVERAGEX already ignores blank values though, so it might be zero values tripping you up rather than blank values. In this case, you could filter for [Net] > 0 rather than NOT ISBLANK ( [Net] ) ).

View solution in original post

1 REPLY 1
AlexisOlson
Super User
Super User

If that is the problem, then you could try this:

Net USD average per Day =
VAR NetPerDay =
    ADDCOLUMNS (
        VALUES ( 'Date'[Date] ),
        "Net", CALCULATE ( SUM ( 'Revenues DB'[Net USD] ) )
    )
RETURN
    AVERAGEX ( FILTER ( NetPerDay, NOT ( ISBLANK ( [Net] ) ) ), [Net] )

 

I'm pretty sure AVERAGEX already ignores blank values though, so it might be zero values tripping you up rather than blank values. In this case, you could filter for [Net] > 0 rather than NOT ISBLANK ( [Net] ) ).

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.