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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
NILU090
Helper I
Helper I

latest non blank values

Hi Team,Please find the datamodel and output that i require.
I want show difference between current value and last non blank value.

I tried NONBLANKVALUE, howeve its not working. 

please help me on this.

 

NILU090_0-1682064251342.png

 

1 REPLY 1
johnt75
Super User
Super User

Try

Diff with previous =
VAR CurrentDate =
    MAX ( 'Date'[Date] )
VAR CurrentValue =
    SELECTEDVALUE ( 'Fact'[Value] )
VAR PrevValue =
    CALCULATE (
        LASTNONBLANKVALUE ( 'Fact'[Date], 'Fact'[Value] ),
        'Date'[Date] < CurrentDate
    )
RETURN
    CurrentValue - PrevValue

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.