Forum Discussion
Power BI Paginated Report with BigQuery DirectQuery – Filters not pushed down
Hi Poojara_D12 ,
I finally found out how to Query Google BigQuery:
I created a datasource with all the columns from my BigQuery View, but when I try to use this datasource in a DataSet I can not enter a query. And I cannot modify this datasource after i saved it. (That's not very comfortable.)
What am I missing here?
Hi m_andel,
You are not missing anything, that is the current design. Power Query handles all query logic internally so the sql text box in the dataset properties is disabled.
So to customize your query or add parameters, edit it directly inside the Power Query editor using Value.NativeQuery.
Inside the M code use a parameterized native query like this:
let
Source = Value.NativeQuery(
BigQuery.Database(null),
"SELECT * FROM ENTER_NAME WHERE Date >= @StartDate AND Date <= @EndDate",
[StartDate = Parameters!StartDate.Value, EndDate = Parameters!EndDate.Value]
)
in
Source
Save and close the power query the dataset will now return filtered data directly from BigQuery.
Thanks and regards,
Anjan Kumar Chippa
- m_andel9 months agoHelper I
Hi, v-achippa
I can now load data. My last issue is the connection to powerbi. Is it possible to use a google service account with a key file? I have found no option to configure the connection this way.
- v-achippa9 months agoCommunity Support
Hi m_andel,
Currently using a google service account key file is not supported in Power Query based connections within Power BI Report Builder or the Power BI Service. Only OAuth authentication with a user account is supported, so please use OAuth sign-in for now.
Thanks and regards,
Anjan Kumar Chippa