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
Instead of just adding time zone Offsets (which Many suggest) ,
use the Following Power Query
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"
This Give two Dates, base tiime zone of the refresh and the "Local Time" I am in Pacific and just Ran this in Desktop ift Gives teh Following
Because we have just "Sprung Forward" to Summer time
on Power BI Service it Gives the Following
- vbaker8 years agoHelper I
How are you automatically accounting for Daylight Saving Time?
- Anonymous8 years agoNot applicable
We have removed the time indication and are just showing the date as the lazy solution, or where it doesn't really matter if the time is out by an hour not bothering to fix it.
To deal with this across all the dashboards in the future we will
1) Only publish the date where time doesn't matter.
2) Adopt the solution suggested by Anonymous and using a SQL database that we have access to.
3) Another alternative is to scrape the time from a webpage that specifies the time in Summer time. Although I don't like the idea of introducing a dependency on an external website in out dashboards.