Google Cloud/BigQuery: Difference between revisions
From charlesreid1
(→Gcloud) |
|||
| Line 1: | Line 1: | ||
=Installing | =Installing= | ||
==Gcloud== | ==Gcloud== | ||
| Line 24: | Line 24: | ||
Specifically: https://github.com/GoogleCloudPlatform/google-cloud-python/tree/master/bigquery | Specifically: https://github.com/GoogleCloudPlatform/google-cloud-python/tree/master/bigquery | ||
=Using= | |||
==Using from gcloud== | |||
==Using from Python== | |||
=Resources= | =Resources= | ||
Revision as of 01:09, 24 October 2017
Installing
Gcloud
BigQuery Client Library
There is a long list of client libraries for Google Cloud provided here: https://cloud.google.com/apis/docs/cloud-client-libraries
The Python API bundles each component separately, and not everything comes with the client library by default. For example, if you want to use BigQuery, you have to install the BigQuery API components. If you want to use PubSub, you have to install the PubSub API components. Installing one does not necessarily install the other.
Python API
To use BigQuery from Python, you need to install the Google Cloud Python API, plus BigQuery bindings. Use pip:
$ pip3 install --upgrade google-cloud-bigquery
Link/reference: https://cloud.google.com/bigquery/docs/reference/libraries
Also see: https://github.com/GoogleCloudPlatform/google-cloud-python
Specifically: https://github.com/GoogleCloudPlatform/google-cloud-python/tree/master/bigquery
Using
Using from gcloud
Using from Python
Resources
The Google Cloud podcast has a nice episode talking about BigQuery under the hood: https://www.gcppodcast.com/post/episode-94-big-query-under-the-hood-with-tino-tereshko-and-jordan-tigani/