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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
steph94
New Member

datetime.localnow() returns 'a datetime value set to the current date and time on the system.'

Hi, quick question.. datetime.localnow() returns 'a datetime value set to the current date and time on the system.' My question is which system? I'v had such mess with shceduling a refresh on a report and it appears that it may be a result of the times on the sharepoint list the report is using, are by default in UTC rather than my local time..? I schedule refresh my report after midnight which in turn updates which jobs in the report are displayed as 'Active'. However the datetime.localnow might be returning the local UTC time rather than my timezone which is GMT.. This is the query for context: Table.AddColumn(#"Changed Type", "Today Active/Not Active", each if DateTime.Date(DateTime.LocalNow())=[Project Start] then "Active" else if DateTime.Date(DateTime.LocalNow())>[Project Start] and DateTime.Date(DateTime.LocalNow())<=[Projected Finish] then "Active" else "Not Active") Any advice or ideas would be really helpful!

1 ACCEPTED SOLUTION
ray_ux
Memorable Member
Memorable Member

Yes times in the powerBI service are UTC
And yes it's super annoying
You can wrap it in a time zone conversion though

View solution in original post

2 REPLIES 2
ray_ux
Memorable Member
Memorable Member

Yes times in the powerBI service are UTC
And yes it's super annoying
You can wrap it in a time zone conversion though

thanks! i have been so confused!😅

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors