Skip to main content
Snowflake

Snowflake

Snowflake provides a cloud data platform where publishers can unify and analyze audience and advertising data securely.

Setup

Troubleshooting

Overview

The Snowflake integration enables publishers to leverage Permutive’s bi-directional data capabilities with their Snowflake data warehouse. This integration operates in two modes: Routing (Destination): Stream first-party event data from Permutive to Snowflake. Read more in Routing documentation.
Routing capability requires the Routing package in addition to Core Platform. Contact your Customer Success Manager to enable Routing.
Connectivity (Source): Import audience data from your Snowflake warehouse into Permutive for cohort building and activation across your publisher inventory. Use cases include:
  • Unifying first-party audience data with advertising and CRM data in Snowflake
  • Building a single view of your audience by combining Permutive data with other data sources
  • Creating segments and insights in Snowflake for activation in Permutive
  • Running custom analytics and reporting on raw Permutive event data

Environment Compatibility

Prerequisites

For Routing (exporting data to Snowflake):
  • Active Snowflake account with appropriate permissions
  • Ability to create database, schema, tables, stages, and pipes in Snowflake
  • Ability to create users with key-pair authentication (password authentication is not supported)
  • Access to a Snowflake warehouse for data loading operations
  • Snowflake account URL in the format: https://<organization-id>-<account-id>.snowflakecomputing.com

Setup

Setting up Snowflake routing involves creating a dedicated database, schema, user, and role in your Snowflake instance, then configuring key-pair authentication so Permutive can stream event data via Snowpipe. Once configured, Permutive will complete the storage integration and begin streaming data automatically.

Prerequisites

  • Active Snowflake account with administrative permissions
  • Ability to create databases, schemas, users, roles, and storage integrations
  • Access to a Snowflake warehouse
  • Snowflake account URL in the format: https://<organization-id>-<account-id>.snowflakecomputing.com
Snowflake Routing requires key-pair authentication. Password authentication is not supported.
For the complete step-by-step setup guide with SQL scripts and permissions configuration, see Setting Up Snowflake Routing.

What Happens After Setup

Once routing is active:
  1. Tables are created automatically for events, aliases, and segment metadata
  2. Events stream via Snowpipe in approximately 5-minute or 500MB batches
  3. All event types appear in a single EVENTS table with an EVENTNAME column to distinguish types
  4. Schemas update automatically when you add new event types or properties

Data Types

When Routing is enabled, Permutive creates the following tables in your Snowflake instance to store event data and metadata:
The main events table contains all user interaction data collected by Permutive.
TIMESTAMP
The timestamp when the event occurred.
VARCHAR
Your Permutive organization identifier.
VARCHAR
The workspace (project) ID where the event was collected.
VARCHAR
Unique identifier for the page view session.
VARCHAR
Unique identifier for the user session.
VARCHAR
The Permutive user identifier.
VARCHAR
Unique identifier for this specific event.
VARCHAR
The name/type of the event (e.g., PageView, Pageview, SlotViewable).
ARRAY
Array of segment IDs (integers) that the user belongs to at the time of the event.
OBJECT
JSON object containing event-specific properties and metadata. Structure varies by event type.
Contains user identity synchronization data for cross-device and cross-context tracking.
TIMESTAMP
The timestamp when the alias sync occurred.
VARCHAR
Type of sync event (e.g., “alias_sync”).
VARCHAR
The Permutive user identifier.
VARCHAR
The workspace (project) ID.
VARCHAR
The external identifier being synced (e.g., hashed email, device ID).
VARCHAR
The type/tag of the external identifier (e.g., “email_sha256”, “device_id”).
Metadata table containing information about segments configured in your Permutive workspace.
TIMESTAMP
When the segment metadata was inserted/updated in Snowflake.
VARCHAR
The workspace (project) ID.
VARCHAR
Human-readable name of the segment.
ARRAY
Array of tags associated with the segment.
OBJECT
JSON object containing additional segment metadata (e.g., description, creation date).
VARCHAR
The segment ID number as a string.

Troubleshooting

Symptoms: No data visible in the EVENTS table after completing Routing setup.Solutions:
  1. Wait at least 5-10 minutes after setup completion for initial data flow
  2. Verify Snowpipe is running:
  3. Check pipe status - it should show as “RUNNING”
  4. Verify the storage integration was created successfully:
  5. Contact Support if no data appears after 15 minutes
Symptoms: Authentication failures when connecting to Snowflake, errors like “Invalid key” or “Authentication failed”.Solutions:
  1. Ensure the private key is in PKCS8 PEM format:
  2. When setting RSA_PUBLIC_KEY on the Snowflake user, ensure you:
    • Remove the -----BEGIN PUBLIC KEY----- header
    • Remove the -----END PUBLIC KEY----- footer
    • Concatenate all remaining lines into a single string (no line breaks)
  3. Verify the public key is correctly attached to the user:
    Check the RSA_PUBLIC_KEY_FP field is populated
  4. If using an existing key pair, regenerate a fresh key pair following the setup instructions
Symptoms: Errors indicating insufficient permissions when Permutive attempts to create tables, stages, or pipes.Solutions:
  1. Verify the role has all required permissions:
  2. Ensure the following grants are present:
    • USAGE on database
    • USAGE, CREATE TABLE, CREATE STAGE, CREATE PIPE on schema
    • CREATE INTEGRATION on account
    • OPERATE on future pipes
    • USAGE on warehouse
  3. If any grants are missing, re-run the permission grant commands from the setup guide
  4. Ensure the user’s default role is set correctly:

Changelog

No changes listed yet. For detailed changelog information, visit our Changelog.