Forum Discussion
Set local time zone Power BI Service
Hi Rajiv,
Your solution seems the most elegant but I am not quite following what you are saying. I am currently using a Calendar table which is marked as date table already. Should I be adding a column to that date table and adding a local timezone calculation to it?
I added a new table along side my other data sources. It just has one record of the local time. Mark that as Date Table and the other date times follow accordingly.
let
Source = Json.Document(Web.Contents("http://worldtimeapi.org/api/timezone/Australia/Adelaide")),
#"Converted to Table" = Table.FromRecords({Source}),
#"Changed Type" = Table.TransformColumnTypes(#"Converted to Table",{{"abbreviation", type text}, {"client_ip", type text}, {"datetime", type datetimezone}, {"day_of_week", Int64.Type}, {"day_of_year", Int64.Type}, {"dst", type logical}, {"dst_from", type datetime}, {"dst_offset", Int64.Type}, {"dst_until", type datetime}, {"raw_offset", Int64.Type}, {"timezone", type text}, {"unixtime", Int64.Type}, {"utc_datetime", type datetime}, {"utc_offset", type text}, {"week_number", Int64.Type}})
in
#"Changed Type"