Forum Discussion
last time refresh
- 10 years ago
Hi,
Maybe this will solution will help,
http://www.powerpivotpro.com/2010/11/add-a-last-refreshed-date-readout/
I will try tommorow and update :-)
- 10 years ago
Hi nir,
You can add a calculated column (Last Refresh Column) in the model with the formula =NOW()
And measure Last Refresh Date :=MAX(Table[Last Refresh Column])
Since calculated columns are calculated only on model refresh - it will make sure the calc is right
No Need - the Powerquery Solution I Provided accurately reporst the local time irrespective of the location where the data was refreshed
Anonymous
Unfortunately, I don't believe that is accurate.
In the Eastern Time Zone, we are currently -4, however during DST we are -5, so we would need to modify the "DateTimeZone.FixedUtcNow(),-8" during each season.
let
Source = #table(type table[LastRefresh=datetime], {{DateTimeZone.LocalNow()}}),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"LastRefresh", type datetimezone}}),
#"Changed Type with Locale" = Table.TransformColumnTypes(#"Changed Type", {{"LastRefresh", type datetimezone}}, "en-US"),
#"Added Custom1" = Table.AddColumn(#"Changed Type with Locale", "Last Refresh Local", each DateTimeZone.SwitchZone(DateTimeZone.FixedUtcNow(),-8)),
#"Changed Type1" = Table.TransformColumnTypes(#"Added Custom1",{{"Last Refresh Local", type datetimezone}})
in
#"Changed Type1"