Forum Discussion
Error when refreshing a single query in Service -- DataSource.Error: ODBC: ERROR [42000]
- 5 days ago
Hi GiselaV,
Based on the error message, I suspect the issue is related to the Google BigQuery Billing Project ID, rather than the credentials themselves.The important point is that the BigQuery project used to execute and bill queries can be different from the project where your actual tables are stored.
If you don't explicitly specify a Billing Project ID, the Power BI BigQuery connector can automatically select the first available project returned by Google. This could explain why the error mentions a project you don't recognise.
Hope this helps!
Best Regards,
Maruthi
LinkedIn - http://www.linkedin.com/in/maruthi-siva-prasad/
X - Maruthi Siva Prasad - (@MaruthiSP) / X
Hi GiselaV,
The error message points quite specifically to the BigQuery project being used to create the query job rather than necessarily to the credentials for the source tables themselves.
BigQuery requires the identity running the refresh to have bigquery.jobs.create on the project from which the query job is executed. That project can be different from the project that actually contains the tables.
Microsoft documents this exact Power BI connector error and recommends explicitly setting the Billing Project ID rather than allowing the connector to select the first available project automatically.
For example, the connection can be defined as:
Source = GoogleBigQuery.Database([BillingProject="your-billing-project-id"])If the refresh is occurring through the Power BI Service or a gateway, I would also verify that the identity used by that service connection has bigquery.jobs.create on that billing project, while still retaining the required permissions such as bigquery.tables.getData on the actual source tables.
That distinction may also explain why the same report/query works in Desktop but fails in Service: the two refresh contexts may be authenticating differently or using a different project as the query/billing project.
I would therefore check the project ID named directly in the error first, then confirm which BillingProject Power BI is actually using before recreating the model or changing unrelated transformations.
AI-assisted drafting: AI was used to help structure and phrase this response. I reviewed and validated the technical content before posting.