diff --git a/docs/accessing-data/connecting.mdx b/docs/accessing-data/connecting.mdx index 44d87d3ce..98e66106a 100644 --- a/docs/accessing-data/connecting.mdx +++ b/docs/accessing-data/connecting.mdx @@ -43,13 +43,17 @@ This query will return the XLM balances for all Stellar wallet addresses, ordere There are multiple [BigQuery API Client Libraries](https://cloud.google.com/bigquery/docs/reference/libraries) available. -The following example uses Python to access the Hubble dataset. +The following example uses Python to access the Hubble dataset. Use [this guide](https://cloud.google.com/python/docs/setup) for help setting up a python development environment. Install the client library locally, and configure your environment to use your Google Cloud Project: ```bash +# verify python version +python3 --version +# if you do not have pip, install it +python -m pip install --upgrade pip pip install --upgrade google-cloud-bigquery gcloud config set project PROJECT_ID ``` @@ -79,7 +83,7 @@ for table in tables: -Run the example below to show how to run a query and print the results: +Run the example below to run a query and print the results: @@ -129,6 +133,6 @@ To connect Hubble as a data source: And you're connected! -General information about Looker Studio can be found [here](https://support.google.com/looker-studio/?hl=en#topic=6267740). +General information about Looker Studio can be found [here](https://support.google.com/looker-studio/). General information about connecting data sources can be found [here](https://support.google.com/looker-studio/topic/6370331?hl=en&ref_topic=7441382&sjid=14945902445646860578-NA). diff --git a/docs/accessing-data/optimizing-queries.mdx b/docs/accessing-data/optimizing-queries.mdx index 1e7206f91..2b5c68676 100644 --- a/docs/accessing-data/optimizing-queries.mdx +++ b/docs/accessing-data/optimizing-queries.mdx @@ -46,7 +46,8 @@ select datetime_trunc(batch_run_date, month) as `month`, type_string, count(id) as count_operations from `crypto-stellar.crypto_stellar.history_operations` -where batch_run_date >= '2023-01-01T00:00:00' +-- batch_run_date is a datetime object, formatted as ISO 8601 +where batch_run_date > '2023-01-01T00:00:00' group by `month`, type_string order by `month` diff --git a/docs/accessing-data/overview.mdx b/docs/accessing-data/overview.mdx index fd9e0e048..dbc715ee8 100644 --- a/docs/accessing-data/overview.mdx +++ b/docs/accessing-data/overview.mdx @@ -5,9 +5,9 @@ sidebar_position: 0 ## What is Hubble? -Hubble is an open-source, publicly available dataset that provides a complete historical record of the Stellar network. Similar to Horizon, it ingests and presents the data produced by the Stellar network in a format that is easier to consume than the performance-oriented data representations used by Stellar Core. The dataset is hosted on BigQuery–meaning it is suitable for large, analytic workloads, historical data retrieval and complex data aggregation. **Hubble should not be used for real-time data retrieval and cannot submit transactions to the network.** +Hubble is an open-source, publicly available dataset that provides a complete historical record of the Stellar network. Similar to Horizon, it ingests and presents the data produced by the Stellar network in a format that is easier to consume than the performance-oriented data representations used by Stellar Core. The dataset is hosted on BigQuery–meaning it is suitable for large, analytic workloads, historical data retrieval and complex data aggregation. **Hubble should not be used for real-time data retrieval and cannot submit transactions to the network.** For real time use cases, we recommend [running an API server](/docs/run-api-server). -This guide describes when to use Hubble and how to connect. For more information regarding underlying data structures, queries and examples, please refer to the Hubble Technical Docs under APIs. +This guide describes when to use Hubble and how to connect. For more information regarding underlying data structures, queries and examples, please refer to [Viewing Metadata](/docs/accessing-data/viewing-metadata) and [Optimizing Queries](/docs/accessing-data/optimizing-queries). ## Why Use Hubble?