Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow string for copy sources, query destination, and default dataset #7560

Conversation

tswast
Copy link
Contributor

@tswast tswast commented Mar 26, 2019

This removes a few more cases where it was required to create a
TableReference or DatasetReference.

  • Allow a string for destination in QueryJobConfig .
  • Allow a string for default_dataset in QueryJobConfig .
  • Allow a list of strings for sources in Client.copy_table.

Closes #7558

This removes a few more cases where it was required to create a
TableReference or DatasetReference.

* Allow a string for destination in QueryJobConfig .
* Allow a string for default_dataset in QueryJobConfig .
* Allow a list of strings for sources in Client.copy_table.
@tswast tswast requested a review from crwilcox as a code owner March 26, 2019 18:11
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 26, 2019
@tswast
Copy link
Contributor Author

tswast commented Mar 26, 2019

CC @lbristol88

bigquery/google/cloud/bigquery/client.py Outdated Show resolved Hide resolved
bigquery/google/cloud/bigquery/client.py Show resolved Hide resolved
bigquery/google/cloud/bigquery/client.py Outdated Show resolved Hide resolved
bigquery/google/cloud/bigquery/client.py Outdated Show resolved Hide resolved
bigquery/google/cloud/bigquery/job.py Outdated Show resolved Hide resolved
bigquery/google/cloud/bigquery/job.py Outdated Show resolved Hide resolved
bigquery/google/cloud/bigquery/job.py Outdated Show resolved Hide resolved
Rename the helper to `_table_arg_to_table_ref` and always return a
TableReference when something sensible is passed in.

Add a second helper `_table_arg_to_table` that always returns a `Table`,
which is needed in `list_rows` and `insert_rows` because only a `Table`
contains a schema.
@JustinBeckwith JustinBeckwith merged commit 39c1efc into googleapis:master Mar 27, 2019
@tswast tswast deleted the issue7558-reference-objects-in-job-configs branch March 27, 2019 18:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants