Google Cloud/BigQuery: Difference between revisions
From charlesreid1
| Line 3: | Line 3: | ||
==Gcloud== | ==Gcloud== | ||
==Python API== | ==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: | To use BigQuery from Python, you need to install the Google Cloud Python API, plus BigQuery bindings. Use pip: | ||
| Line 14: | Line 20: | ||
Also see: https://github.com/GoogleCloudPlatform/google-cloud-python | Also see: https://github.com/GoogleCloudPlatform/google-cloud-python | ||
Specifically: https://github.com/GoogleCloudPlatform/google-cloud-python/tree/master/bigquery | |||
=Resources= | =Resources= | ||
Revision as of 01:05, 24 October 2017
Installing and Using
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
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/