E57A BigQuery Snippets: Use autodetected location (#8341) · googleapis/google-cloud-python@7dc367e · GitHub
[go: up one dir, main page]

Skip to content

Commit 7dc367e

Browse files
grantbusunkim96
authored andcommitted
BigQuery Snippets: Use autodetected location (#8341)
1 parent 0737737 commit 7dc367e

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

bigquery/docs/snippets.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -443,12 +443,8 @@ def test_load_and_query_partitioned_table(client, to_delete):
443443
bigquery.ScalarQueryParameter("end_date", "DATE", datetime.date(1899, 12, 31)),
444444
]
445445

446-
query_job = client.query(
447-
sql,
448-
# Location must match that of the dataset(s) referenced in the query.
449-
location="US",
450-
job_config=job_config,
451-
) # API request
446+
# API request
447+
query_job = client.query(sql, job_config=job_config)
452448

453449
rows = list(query_job)
454450
print("{} states were admitted to the US in the 1800s".format(len(rows)))

0 commit comments

Comments
 (0)
0