Google BigQuery cloud data source
This article describes how to set up the Google BigQuery cloud data source.
The Google BigQuery cloud data source is currently in Early Access and is only available to select customers. If you are interested in using Google BigQuery as a data source, contact your Tealium Support representative.
A cloud data source links your cloud data warehouse or database to Tealium, allowing you to import rows as events.
For more information, see About cloud data sources.
Data types
The Google BigQuery data source supports all Google BigQuery data types. To ensure data is imported correctly, map the Google BigQuery data types according to the following guidelines:
Google BigQuery | Tealium |
---|---|
Numeric data types | Number attributes |
String and binary data types | String attributes |
Logical data types | Boolean attributes |
Date and time data types | Date attributes |
Arrays | Array of strings, array of numbers, or array of booleans |
JSON | String attributes |
STRUCT | See Importing STRUCT columns. |
For more information, see Google BigQuery: Data types.
Create a connection
Tealium uses the OAuth 2.0 flow to authenticate with Google. This process requires a service account and a private key file. Before you proceed, you must create a service account in Google and create a public/private key pair.
To configure a new connection, enter the following connection details:
- Dataset: The name of the dataset within the specified project. Do not include the project name.
- Project ID: The project ID of your Google Cloud project.
- Service Account Email Address: The generated email address that is unique to the service account.
- JSON Key File: Upload the generated private key file for the service account.
After you connect to Google BigQuery, select a table or view from the Data Selection list.
For more information, see Google for Developers: Using OAuth 2.0 for Server to Server Applications.
Query mode
For a general overview, see Query modes.
For modes that use Timestamp, the selected timestamp column must be the type TIMESTAMP
.
For more information, see Google BigQuery: TIMESTAMP.
For modes that use Incrementing, the selected numeric column must increment in value for every row added. Use whole number types, such as INT64
instead of FLOAT
or DECIMAL
.
For more information, see Google BigQuery: Numeric types.
WHERE clause
For a general overview, see SQL Query.
The WHERE
clause does not support subqueries from multiple tables. To import data from multiple Google BigQuery tables, create a view in Google BigQuery and select the view in the data source configuration.
Importing STRUCT columns
BigQuery STRUCT
columns cannot be imported directly into Tealium. To import data from a STRUCT
column, create a view with the STRUCT
fields flattened into separate columns.
For example, you might have addresses defined as a STRUCT
:
shipping_address STRUCT<
street STRING,
city STRING,
state STRING,
postal_code STRING,
country STRING
>
To create a view with these address fields flattened into separate columns, use a SQL statement like this:
CREATE OR REPLACE VIEW ecommerce.order_shipping_view AS
SELECT
order_id,
customer_id,
shipping_address.country AS country,
shipping_address.postal_code AS postal_code
FROM
ecommerce.orders;
The flattened STRUCT
columns can be imported and mapped like the other supported data types.
This page was last updated: September 24, 2025