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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
sieed
Helper II
Helper II

Power BI.com manual refresh breaking visuals

I have create a calculated column which computes the "Minutes Since last refresh" and used a card to diaply this column.

 

Here's the calculate column formula: Num Mins Since last Refresh = datediff(Tablename(datetime), now(), minute). 

 

datetime is equal to  DateTimeZone.ToLocal(DateTime.AddZone(DateTime.LocalNow(),-5)). So it gives me central time. 

Now, when I do a "refresh now" in power bi web, the "Minutes Since Last Refresh" breaks and gives me the following error: 

Couldn't load the data for this visual
 
The query referenced calculated column 'TableName'[Num Mins Since Last Refresh] which does not hold any data because evaluation of one of the rows caused an error.
Please try again later or contact support. If you contact support, please provide these details.
 
I understand that power bi service uses some different time zone rather than the current local time. The questions is, what do I do to fix this? 
1 REPLY 1
v-huizhn-msft
Employee
Employee

Hi @sieed,

You want to convert UTC to local time, right? If it is, you can use the DateTimeZone.SwitchZone function to transfer them to same time Zone. Or you can use DateTimeZone.LocalNow().

Reference links.

Convert utc to local time zone using Power Query

Display Last Refreshed Date in Power BI


Best Regards,
Angelia

 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors