0
votes

I'm looking at BQ PY Client Libraries:

There used to be two different operations to query a table

client.run_async_query()

client.run_sync_query()

But in the latest version (v1.3) it seems there's only one operations to execute a query, Client.query(). Did I understand correctly?

And looking at GH code it looks Client.query() just returns the query job, not the actual query results / data.... Making me conclude it works in a similar way as client.run_async_query().. there's no replacement for client.run_sync_query() operation anymore which return query results (data) synchronously / immediately?

Thanks for the clarification!

Cheers!

1

1 Answers

0
votes

Although .run_sync_query() has been removed, the Query reference says that short jobs may return results right away if they don't take long to finish:

query   POST /projects/projectId/queries 

Runs a BigQuery SQL query and returns results if the query completes within a specified timeout.