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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Refresh Google Sheets in Power BI

Hello All,

 

Google sheets donot allow access more than 100 requests per 100 sec. I get an error when I try to access a Google Sheet more than 5 times at a time or Refresh more than 5 Sheets at a time in Power BI. Ref. Link Below:

 
As in the Above Link, There is a limit on Google Spreadsheet API access rate: 10 request per user per sec. (max)
error.jpg
I always get the above error every time I refresh Google sheets in Power BI. (429) UNKNOWN
Please suggest How to Refresh a report inPower BI Services which in turn is fetching data from multiple Google Sheets
 
Thanks
 
 
 
1 ACCEPTED SOLUTION
v-yuezhe-msft
Employee
Employee

@Anonymous,

You can use Function.InvokeAfter()  function to set wait time between calls in Power Query.

Alternatively, you can use R script to refresh Google sheets and set Sys.sleep(30) as described in the following similar thread.
https://community.powerbi.com/t5/Desktop/HTTP-429-Error-while-refreshing-data-from-Google-Sheets-using-R/td-p/264416

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-yuezhe-msft
Employee
Employee

@Anonymous,

You can use Function.InvokeAfter()  function to set wait time between calls in Power Query.

Alternatively, you can use R script to refresh Google sheets and set Sys.sleep(30) as described in the following similar thread.
https://community.powerbi.com/t5/Desktop/HTTP-429-Error-while-refreshing-data-from-Google-Sheets-using-R/td-p/264416

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Function.InvokeAfter()  worked for me, with delay=20sec.

 

Thankyou v-yuezhe-msft.

Anonymous
Not applicable

Hello All,

 

I am authenticating and dowloading Google sheets in my Power BI Desktop. I am using Function.InvokeLater(..20 sec..) between two sheetIDs download in the same Google Sheet. But right now Each time I download new Google (Individual) sheetID I generate a new Access Token. Should I save Access Tokens in a DB and use the same Token for sheets downloaded within 1 hour of the Access Token generation?? And after the Token expires and I am trying to access Google Sheet, I would regenerate new Token.

 

I this case will I get (429) error while accessing consecutive Google Sheets, I will still have to use:  Function.InvokeLater(..20 sec..)

 

Is there an alternative way. 

 

Thanks for your help.

Anonymous
Not applicable

Hello All,

 

I am trying to figure out, how many read calls it takes to read/refresh Google Spreadsheet (70 tabs) in Power BI (1 tab at a time). My quota limit in Google Sheet API is 100 requests in 100 sec per user. Should I try to upgrade my quota limit in Google Sheet API??? or read multiple Tabs in Multiple Read Call??

 

 

Thanks for your answer,

Vithi Mittal.

Anonymous
Not applicable

I tried Sys.Sleep(5) in R script, But each sheet executes reading of Google Sheet and Access to Google API when I Refresh All.

 

When I try to get ALL sheets at once, gs_download() is executed as many number of times as the number of sheets and the Sys.Sleep(5) is executed as many times as the number of sheets, but the READ begins for ALL sheets at the same time, thus the error...

Sys.Sleep(30)
library(googlesheets)
suppressMessages(gs_auth(token = "~/person.rds", verbose = FALSE))
temp <- tempfile(fileext = ".xlsx")
gs_download(gs_key("1k20...1xds"), to=temp, overwrite=TRUE)
require(xlsx)
x1 <- read.xlsx(temp, sheet = 1)




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors