I’m running into an issue with scheduling a BigQuery query through Terraform using a service account.Even though SA is granted permissions to access the dataset I'm still not able to schedule through SA.
Error: Failed to start BigQuery job. Error: Access Denied: Table wf-gcp-us-ae-sf-prod:curated_data_hub.tbl_fact_order_financials: User does not have permission to query table wf-gcp-us-ae-sf-prod:curated_data_hub.tbl_fact_order_financials, or perhaps it does not exist. User: product-grouping-sa@wf-gcp-us-pg-product-kit-prod.iam.gserviceaccount.com. Please make sure the resource exists and follow http://cloud/iam/docs/granting-changing-revoking-access to grant permissions to the user. See required permissions in Transfer guides.
permissions added :
resource "google_bigquery_dataset_iam_member" "product_grouping_sa_querier" {
project = google_project.google_project.project_id
dataset_id = "curated_data_hub"
role = "organizations/825417849120/roles/tf_wf_ae_svc_bigquery_querier"
member = "serviceAccount:product-grouping-sa@wf-gcp-us-pg-product-kit-prod.iam.gserviceaccount.com"
}
Hi @hj857p I think you meant to tag BigQuery in this post, not Bigtable.