I have a question regarding Hi Metabase Community,
I'm currently using Metabase connected to Google BigQuery and would like to avoid specifying the dataset name in every SQL query.
Current Setup:
- Database Type: BigQuery
- Project ID:
rbt-data-ksa
- Dataset Name:
dwh_reporting
- Datasets (in Metabase settings):
dwh_reporting
(listed under "Only these..." as a comma-separated value)
Issue:
When I run a simple query like:
SELECT *
FROM `customer_ltv`
LIMIT 10;
I get the following error:
400 Bad Request POST https://www.googleapis.com/bigquery/v2/projects/rbt-data-ksa/queries {
"code": 400,
"errors": [
{
"domain": "global",
"message": "Table \"customer_ltv\" must be qualified with a dataset (e.g. dataset.table).",
"reason": "invalid"
}
],
"message": "Table \"customer_ltv\" must be qualified with a dataset (e.g. dataset.table).",
"status": "INVALID_ARGUMENT"
}
However, if I fully qualify the table name like this:
SELECT *
FROM `rbt-data-ksa.dwh_reporting.customer_ltv`
LIMIT 10;
The query runs successfully.
What I'm Trying to Achieve:
I want to set dwh_reporting
as the default dataset so I can run queries without having to fully qualify the table name each time.
Questions:
- Is there a way in Metabase to set a default dataset for BigQuery so that I can omit the dataset name in my queries?
- Does the absence of a Service Account JSON file affect this behavior?
- Is there a specific configuration I need to adjust in Metabase or BigQuery to make this work?
Any guidance would be greatly appreciated!
Thanks in advance!