Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hello,
I want to copy latest value of a mesure on the future even it s equal to 0 or null.
Exemple: copy 38068 to last date on the calendar.
Could you assist please with DAX formulas?
Thank you.
Regards,
Any suggestions?
Hi @Marwen89 ,
Try to create a measure like below:
Measure =
VAR LastDate_ =
CALCULATE (
MAX ( 'Table'[Date] ),
ALL ( 'Table' )
)
var max_ = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),'Table'[Date]=LastDate_))
VAR result =
CALCULATE (
SUM('Table'[Value]),
DATEADD('Calendar'[Date],1,DAY)
)
RETURN
if(max('Calendar'[Date])>=LastDate_,max_,Result)
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello @V-lianl-msft ,
it does not work for future date,
here i have last value at 04/04/2022, i want it copied for the future date.
Thanks,
@BeaBF I really want to copy the latest value of "In Transit Retail TRV Picture end period (qty)" even is null for th future, Seen that "In Transit Retail TRV Picture end period (qty)" is a measure.
A DAX formulas is needed .
Thanks,
Regards,
@Marwen89 you can do it in Power Query, thorught Table.FillDown function, like this:
#"NEW STEP = Table.FillDown(#"PREVIOUS STEP",{"In Transit Retail TRV Picture end period (qty)"})
in
#"NEW STEP"
BF
@Marwen89 if you have a table like this:
you can create a calculated column to do so:
"In Transit Retail TRV Picture end period (qty)" is a measure,
CALCULATE (SUM ( 'In Transit Retail, Supply'[TransitPictures Quantity] ), DATEADD ( LASTDATE ( 'Period'[Date] ), 1, DAY ))
User | Count |
---|---|
20 | |
18 | |
17 | |
11 | |
7 |
User | Count |
---|---|
29 | |
28 | |
13 | |
12 | |
12 |