> ## Documentation Index
> Fetch the complete documentation index at: https://docs.inflection.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Export to Data Warehouse

> Export raw data to your data warehouse to support marketing analytics.

Exporting marketing data from Inflection to your data warehouse enables your marketing, operations, and data teams to build custom reports and run analytics in their BI tools. Track email engagement, journey performance, and form submissions alongside your product and revenue data for comprehensive growth insight

## Data You Can Export

Inflection allows you to export marketing data (email events, journey activity, and form & inbound webhook submissions) directly to your data warehouse. This makes it easier for your marketing, ops, and data teams to create reports and run analytics in their BI tools.

The events and attributes are supported:

| Event Type               | Events                                                                                            | Attributes                                                                                                                                                                                                                    |
| ------------------------ | ------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Email                    | Processed<br />Sent<br />Open<br />Clicked<br />Bounced<br />Spam<br />Unsubscribe<br />Delivered | • Contact: `Inflection Contact ID`, `Contact Email`<br />• Email Asset: `Email Asset ID`, `Email Asset Name`, `Email Asset Link`, `Email event Detail`<br />• Journey: `Run ID`, `Journey ID`, `Journey Name`<br />• Datetime |
| Journey                  | Journey Entered<br />Journey Completed<br />Journey Exited                                        | • Contact: `Inflection Contact ID`, `Contact Email`<br />• Journey: `Run ID`, `Journey ID`, `Journey Name`<br />• Datetime                                                                                                    |
| Forms & Inbound Webhooks | Form Submitted<br />Inbound Webhook Submitted                                                     | • Contact: `Inflection Contact ID`, `Contact Email`<br />• `Datetime`                                                                                                                                                         |

<Tip>
  All ID columns are accompanied by human-friendly names to make querying and dash-boarding easy.
</Tip>

<Info>
  **Journey Completed vs. Journey Exited**: **Journey Completed** is triggered when a record finishes all flow steps in the journey and reaches the end. **Journey Exited** is triggered when a record meets the journey's exit criteria and exits the journey.
</Info>

## Configure Data Warehouse Export

Inflection currently supports importing data from the following data warehouses:

* [Big Query](/connections/warehouses/bigquery)
* [Databricks](/connections/warehouses/databricks)
* [Redshift](/connections/warehouses/redshift)
* [Snowflake](/connections/warehouses/snowflake)

## Manage Data Warehouse Export

Once your data export connection is active, you can review its status, manage what data is being synced, and monitor sync activity via:

* **Sync Settings**: View sync history, sync errors, monitor record counts, and track export status.
* **Connection Details**: Review or edit connection configuration and view SQL snippet used for creating the export tables.

### Sync Settings

The **Sync Details** tab gives you visibility into the status and history of all sync activity.

Here you can:

* See **next scheduled sync time** and the **last completed sync duration**
* Track the **number of records synced** and **total tables updated**
* View a **sync history table** showing:
  * Timestamp of each sync
  * Target table (e.g., `Inflection Activities`, `Entity`)
  * Number of rows inserted or updated
  * Count of any errors
* Filter history by:
  * **Date range** (via calendar selector)
  * **Empty vs. non-empty syncs**

You can also pause the entire sync using the **Pause Sync** button in the top-right corner.

### Connection Details

The **Connection Settings** tab shows the credentials and database details configured for your data warehouse export connection. This is where you can review or update your connection setup.

Here you’ll find:

* **Connection Credentials**
  * **Account Name**: Your data warehouse account identifier
  * **Username**: The user Inflection will authenticate as
  * **Password**: Stored securely and not visible in the UI
* **Database Details**
  * **Connection Name**: Internal name for this export connection
  * **Database**: The destination database for exported data
  * **Schema**: The schema where Inflection will write tables
* **Table Creation SQL (Snowflake only)**
  * Pre-generated SQL code to create the required tables in your warehouse
  * You can **view**, **copy**, or **send** the SQL to your data team

<Info>
  To update credentials or database information, click **Edit Details**. The sync will be paused before making changes.
</Info>

## Table Schema

Inflection exports two tables to your data warehouse:

### 1. `inflection_marketing_activities`

This is the main event log table. Each row corresponds to a single marketing activity or event such as an email send, form fill, or journey entry.

| Column Name             | Data Type | Description                                                                     |
| ----------------------- | --------- | ------------------------------------------------------------------------------- |
| id                      | STRING    | Unique identifier for the event record.                                         |
| event\_name             | STRING    | Name of the event (e.g., "Email Clicked", "Journey Entered", "Form Submitted"). |
| event\_details          | STRING    | Additional metadata about the event (e.g., delay timing, webhook names, etc.).  |
| event\_time             | DATETIME  | UTC timestamp when the event occurred.                                          |
| inflection\_contact\_id | STRING    | Internal ID of the contact within Inflection.                                   |
| contact\_email\_id      | STRING    | Contact's email address.                                                        |
| asset\_id               | STRING    | Unique ID of the asset involved in the event, if applicable.                    |
| asset\_link             | STRING    | Direct URL to the asset.                                                        |
| run\_id                 | STRING    | ID representing the unique run session of a journey.                            |
| journey\_id             | STRING    | ID of the journey where the event occurred.                                     |
| event\_meta             | JSON      | Event’s additional information                                                  |
| created\_at             | DATETIME  | Timestamp when the event was first logged.                                      |
| updated\_at             | DATETIME  | Timestamp when the event record was last updated.                               |

### 2. `inflection_marketing_entities`

This is a supporting table used for mapping IDs in the event table to their corresponding names and types. It improves readability and enables easier joins in BI tools.

| Column Name        | Data Type | Description                                                                   |
| ------------------ | --------- | ----------------------------------------------------------------------------- |
| id                 | STRING    | Unique identifier of the entity (e.g., journey, template, flowstep).          |
| entity\_type       | STRING    | Type of entity (e.g., `JOURNEY`, `TEMPLATE`, `FLOW_STEP`).                    |
| entity\_name       | STRING    | Human-readable name of the entity.                                            |
| entity\_meta\_info | STRING    | Additional metadata or context for the entity (e.g., delay info, linked IDs). |
| is\_deleted        | BOOLEAN   | Boolean which says entity deleted or not                                      |
| created\_at        | DATETIME  | Timestamp when the entity was first recorded.                                 |
| updated\_at        | DATETIME  | Timestamp when the entity record was last modified.                           |

<Tip>
  `entity_type` and `entity_name` can be joined with IDs in the main table to create user-friendly reports and dashboards.
</Tip>

## Permissions & Security

Inflection only requires **table-level permissions** for export:

* `INSERT`
* `UPDATE`
* `DELETE`
* `ALTER`

We do **not** require database or schema-level access.

<Info>
  Databricks requires you to grant `USE CATALOG` and `USE SCHEMA` permissions to Inflection’s service principal.

  These don’t give access to your data; they just let Inflection choose the right catalog and schema when running queries.
</Info>

This ensures you can maintain tight control over what Inflection can access and modify.

## Example Reports You Can Build

Once your data is in the warehouse, you can use any BI tool to generate reports like:

* Journey funnel drop-off
* A/B test performance
* Email click rates over time
* Unsubscribes vs. sends (MoM)
* Cross-journey activity trends

## Troubleshooting & FAQs

**My sync is stuck. What do I do?**

* Check the **Sync Health Status** on the connection page. Common issues include:
  * Table structure mismatch
  * Missing permissions
  * Connection credentials expired
* Contact your data team to validate the table setup or re-run the setup script.
