Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I have a query that shows the last date/time the PowerBI was refreshed. I was hoping to write an additional query that shows how long the query took to refresh. Is this possible?
Refresh query:
let
Source = #table(type table[LastRefresh=datetime], {{DateTime.LocalNow()}})
in
Source
Solved! Go to Solution.
Hi alicia_pbi,
As I know, currently there is no function to get refresh duration of local report, you might need to use other tool to catch it. If you are using powerbi service, you could try to use API to get refesh history. You could refer to Datasets - Get Refresh History for details. Then you could create report based on this , and get time difference like below
Measure 3 = DATEDIFF(MAX(refreshes[Column1.startTime]),MAX(refreshes[Column1.endTime]),SECOND)
Best Regards,
Zoe Zhi
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @alicia_pbi ,
I think that is not possible because, to my knowledge, you cannot control when the queries are executed.
Regards,
Marcus
Dortmund - Germany
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.
Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials
@mwegenerThanks for your response. However I am not trying to control when a query is refreshed. What I am looking for is to have a tile that says last refresh length of time = 20 minutes or however long it took to refresh similar to the other query that has a time stamp of when the query was last refreshed.
I assume that PBI has a way to record the length of time a query is running but I do not know how to query that data.
Thanks!
Hi alicia_pbi,
As I know, currently there is no function to get refresh duration of local report, you might need to use other tool to catch it. If you are using powerbi service, you could try to use API to get refesh history. You could refer to Datasets - Get Refresh History for details. Then you could create report based on this , and get time difference like below
Measure 3 = DATEDIFF(MAX(refreshes[Column1.startTime]),MAX(refreshes[Column1.endTime]),SECOND)
Best Regards,
Zoe Zhi
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.