Skip to content

Commit 410f71e

Browse files
DevStephaniegcf-owl-bot[bot]tswast
authored
docs: update to use query_and_wait in client_query_w_positional_params.py (#1786)
* Updates file * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * Correcting RowIterator * Variable corrections --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Tim Swast <[email protected]>
1 parent 68ebbe1 commit 410f71e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

samples/client_query_w_positional_params.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,10 @@ def client_query_w_positional_params() -> None:
3535
bigquery.ScalarQueryParameter(None, "INT64", 250),
3636
]
3737
)
38-
query_job = client.query(query, job_config=job_config) # Make an API request.
38+
results = client.query_and_wait(
39+
query, job_config=job_config
40+
) # Make an API request.
3941

40-
for row in query_job:
42+
for row in results:
4143
print("{}: \t{}".format(row.word, row.word_count))
4244
# [END bigquery_query_params_positional]

0 commit comments

Comments
 (0)