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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
ricardocamargos
Continued Contributor
Continued Contributor

Replicate last values

 

Hi there,

 

Does anyone know how to replicate the last value for a non-existing rows ?

For example:

 

I have values for the day 1/1/2018 / 1/2/2018 / 1/4/2018...

In this case I don't have value for 1/3/2018, how can I replicate the last value (1/2/2018) if I don't have this day in my table ?

 

*I'm using a date dimension in this visual. 

 

Thank you,

 

Ricardo

1 ACCEPTED SOLUTION
5 REPLIES 5
Greg_Deckler
Community Champion
Community Champion

Typically you do that in Power Query with something like "Fill".



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

@Hi @Greg_Deckler,

 

Thank for your answer,

 

However the dataset doesn't have this row. just my date table.

 

I should use this function "Fill" when the value is blank, right ?

 

Thank you,

 

Ricardo

Hi @ricardocamargos

 

One approach might be to create a Calculated Table with Missing Dates and Values

 

From the Modelling Tab>>>NEW TABLE

 

New Table =
ADDCOLUMNS (
    GENERATESERIES ( MIN ( TableName[Date] ), MAX ( TableName[Date] ) ),
    "Values",
    VAR Maxdate =
        CALCULATE (
            MAX ( TableName[Date] ),
            FILTER ( TableName, TableName[Date] <= EARLIER ( [Value] ) )
        )
    RETURN
        CALCULATE ( SUM ( TableName[Value] ), TableName[Date] = Maxdate )
)

Hi @Zubair_Muhammad,

 

It works.

 

Thank you,

 

Ricardo

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 2026 Power BI update to learn about new features.

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.