Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to query a partitioned table in bigquery from datastudio

This topic was covered for tableau here:

How to query a partitioned table in BigQuery from Tableau

but I don't think you can insert parameters into datastudio yet.

like image 859
Ralph Avatar asked Oct 20 '25 16:10

Ralph


2 Answers

When creating Data Sources you have option to create a custom query, and also opt for Legacy/Standard SQL.

enter image description here

like image 95
Pentium10 Avatar answered Oct 23 '25 08:10

Pentium10


You can use a custom query for your connection to BigQuery. Rather than picking a specific table, provide a query such as:

SELECT *, _PARTITIONTIME AS timestamp
FROM YourPartitionedTable;

Support for standard SQL with this connector was recently launched, and although I can't seem to find a documentation page, it should be possible to enable for the query as well.

like image 45
Elliott Brossard Avatar answered Oct 23 '25 09:10

Elliott Brossard



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!