Google Analytics Sample Dataset for BigQuery

30/11/2019

The sample dataset provides a complete Google Analytics 360 data set that can be accessed via BigQuery. It’s a great way to look at real business data and experiment and learn the benefits of analysing Google Analytics 360 data within BigQuery.

In this article:

Access the dataset

BigQuery has a free tier which allows you to query 1 terabyte per month and store 10 gigabytes. To learn more about pricing see here. You can view your usage via Stackdriver and create alerts based on thresholds.

To access the dataset:

  1. Go to http://bigquery.cloud.google.com.

  2. If you're new to BigQuery, or you don't have a project set up yet, you’ll need to create a project

  3. Select this link to go directly to the dataset.

  4. Click Query Table to run a query.

In the future you can access the dataset within BigQuery by selecting the bigquery-public-data project from the left-hand navigation panel, then select the ga_sessions table under the google_analytics_sample dataset.

Where the data comes from

The sample dataset contains Google Analytics 360 data from the Google Merchandise Store, a real ecommerce store. The Google Merchandise Store sells Google branded merchandise. The data is typical of what you would see for an ecommerce website. It includes the following kinds of information:

  • Traffic source data: information about where website visitors originate. This includes data about organic traffic, paid search traffic, display traffic, etc.
  • Content data: information about the behavior of users on the site. This includes the URLs of pages that visitors look at, how they interact with content, etc.
  • Transactional data: information about the transactions that occur on the Google Merchandise Store website.

Ways to use the dataset

Because it provides actual Google Analytics 360 data from an ecommerce website, the dataset is useful for exploring the benefits of exporting Google Analytics 360 data into BigQuery via the integration. Once you have access to the dataset you can run queries such as those in this guide for the period of 1-Aug-2016 to 1-Aug-2017. For example to see the total pageviews the website received for 1-Jan-2017 you would query the dataset with:

SELECT SUM(totals.pageviews) as TotalPageviews

FROM [bigquery-public-data:google_analytics_sample.ga_sessions_20170101]

Limitations

All users have viewer access to the dataset. This means that you can query the dataset and generate reports but you cannot complete administrative tasks. Data for some adWordsClickInfo and geoNetwork fields have been removed. “Not available in demo dataset” will be the returned for STRING values and “null” will be returned for INTEGER values, when querying these fields. 

* Nguồn: Google Analytics