Use BigQuery as a source: pulling events for reporting

Written by Julie Trenque

Updated on 03/25/2024

1 min

Advanced

Manage your integrations

Analytics

Automation

CDP

CMP

CMS/CRM

Data Warehouses

Developers

Was this content useful?

Data warehouse integrations are available as a premium add-on for our Web Experimentation and Feature Experimentation module. For more information, please contact your Customer Success Manager.

Once you’ve activated BigQuery for a specific project, you can leverage it to create goals in Kameleoon. These goals are designed to use conversions data directly from your BigQuery database. Here’s how to create a goal using BigQuery:

  1. Navigate to the Goals dashboard by clicking on Configure in the navigation menu, followed by clicking Goals.
  1. Inside the Goals dashboard, click on New Goal.
  1. In the pop-up window, you need to provide the following details:
  • Name: Give your goal a descriptive name to identify its purpose.
  • Type: For the Type field, select “Data Warehouse Tracking.”
  • Data Warehouse: Choose “BigQuery” for the Data warehouse field.
  • Project: Select the project from the available options. Only projects with BigQuery activated are listed.
  • Click Next to proceed.
  1. In the next window, you’ll need to provide additional details to complete the goal configuration:
  • Frequency: Define how often you want Kameleoon to update the goal data.
  • BigQuery project ID: Enter your BigQuery project ID to direct the data to the correct location.
  • Region: Select the appropriate region from the provided list.
  • Query: Define the SQL query to retrieve the necessary data from BigQuery.
  • Click Validate to save your goal configuration.

Query format


The query must adhere to a specific format:

SELECT visitor_id, conversion_timestamp FROM your_events_table


Where “visitor_id” is the column representing the unique id of your visitors and “conversion_timestamp” is a column that represents the exact time at which the conversion took place. In BigQuery, the “conversion_timestamp” column must be a Timestamp type column.
If you want to associate a revenue to each conversion, the query should adhere to an alternate format:

SELECT visitor_id, conversion_timestamp, revenue FROM your_events_table


Where “revenue” is a column containing the revenue for each conversion.

Using your BigQuery goal

With the goal created, you can now incorporate it into your Kameleoon campaigns. When setting up an experiment or personalization, you’ll have the option to select this goal in the configuration steps, allowing you to track and analyze specific conversions directly from your BigQuery database.

To learn how to set up a goal in an experiment, please refer to this article.

  • In this article :