# Transactional data

Load transactional data directly into your Apteco CDP alongside individual and contact point data, creating hierarchical relationships and updating records incrementally.

## How transactional tables relate to individuals

Transactional tables connect to the **Individual** table in one-to-many relationships. Each individual can have multiple transaction records, and you can create parent-child relationships between transactional tables.

> [!TIP]
>
> Create multiple sibling transaction tables as well as parent-child structures. The sibling approach works well when you have different transaction types in a single file.

> [!NOTE]
>
> **Example use cases**
>
> **E-commerce order history**
>
> Load customer data with order and product information from repeated rows per customer and order.
>
> Data source includes:
>
> - Customer details
> - Order information (order ID, date, status, payment method)
> - Order items (product, quantity, unit price, total price)
>
> Transactional tables:
>
> - Order (parent: Individual)
> - Order Item (parent: Order)
>
> **Banking transaction history**
>
> Load customer account data with transaction records and categories.
>
> Data source includes:
>
> - Customer details
> - Transaction information (transaction ID, date, amount, type)
> - Transaction categories (category ID, description, merchant)
>
> Transactional tables:
>
> - Transaction (parent: Individual)
> - Transaction Category (parent: Transaction)

## Prerequisites

Before you begin, ensure that:

- You've imported your data source into Orbit
- Your source data includes a unique identifier for each transaction type
- You understand the hierarchical relationships between your transaction types

> [!NOTE]
>
> Duplicate row counts are expected when loading transactional data, as multiple transaction records per individual create repeated rows in the source.
>
> Orbit nets out duplicate rows during the import and ID resolution processing.

## Creating a transactional mapping

You create transactional mappings as part of your data mapping process to a [Customer Data Table](<https://help.apteco.com/en/orbit/connect/data-mappings/customer-data-table/index.md>).

To create a transactional mapping:

1. Go to **Data Mappings** and select **\+ New Data Mapping**.
2. Under **Customer Data Table** select **Create**.
3. Enter a **Name** and select **Create**.
4. Select your **Data Source** from the drop-down list.
5. Select your **Source Group** from the drop-down list.
6. Turn on **Transactional Mapping**.
7. Select an existing **Transaction Table** or select **\+ New Transaction Table**.
8. Enter a descriptive **Transaction Table Name**.
9. Select a **Parent Transaction Table** for hierarchical relationships (leave as default for top-level tables).

   > **Note**
   >
   > You can't edit the parent table setting after creation. Select the correct parent before creating the table.
10. Choose how to name the table in your system:

    - Leave **Use Transaction Table Identifier** selected to add `Transaction` to the name, for example `Transaction (Donations)`. This makes transaction tables easy to tell apart from the standard Apteco CDP tables.
    - Clear **Use Transaction Table Identifier** to use only the name you entered, for example `Donations`.

    Orbit uses the same name for the table's folder in your system. See [Folder structure](<https://help.apteco.com/en/orbit/connect/system-builds/folder-structure/index.md>). You can't change this setting after you create the table.

    > **Caution**
    >
    > Orbit checks the name against your other transaction tables, but not against [User Defined Tables](<https://help.apteco.com/en/orbit/connect/data-mappings/user-defined-table/index.md>) or Apteco CDP tables. If you clear **Use Transaction Table Identifier**, use a name that none of those tables in your system already has.
11. Select **Add**.
12. Repeat for any additional transactional tables.
13. Use the **Transaction Table** drop-down list to control which transactional tables appear as mapping options.

### Changing an existing transaction table

You can't change the **Use Transaction Table Identifier** setting for a transaction table after you've created it. Changing the table's name could break dashboards, audiences, and other resources that use it.

## Mapping columns to transactional tables

After creating your transactional tables, map your source columns to them.

To map columns to a transactional table:

1. Expand the unmapped column you want to assign.
2. Select **Map Column**.
3. Expand the transactional table you want to map to (identified by the arrows icon).
4. Map to either:

   - [Standard transactional columns](<#standard-transactional-columns>)
   - Custom [Attributes](<https://help.apteco.com/en/orbit/connect/data-mappings/attributes/index.md>)

   > **Note**
   >
   > Custom transactional attributes support the same data types as individual attributes. See [Attributes](<https://help.apteco.com/en/orbit/connect/data-mappings/attributes/#adding-an-attribute>).

   > **Example use case**
   >
   > Custom transactional attributes could include order status, payment method, product names, and quantities.

   > **Tip**
   >
   > Use selector types for fields with limited distinct values (such as payment methods or order statuses) to enable efficient filtering and analysis.
5. Apply your [ID Resolution Rules](<https://help.apteco.com/en/orbit/connect/data-mappings/id-resolution-rules/index.md>).
6. Select **Save**, then **Import**.

> [!NOTE]
>
> You must map either **Transaction Date** or **Transaction Source URN** for the load to proceed. At least one of these columns is required.

### Standard transactional columns

Each transactional table includes standard columns you can map to:

| Column | Description | Required |
| --- | --- | --- |
| Transaction Source URN | A unique identifier for the transaction | At least one required column must be mapped |
| Transaction Date | The date the transaction occurred | At least one required column must be mapped |
| Source create date | The date the data source was created | Optional |
| Source update date | The date the data source was last updated | Optional |

## Building and deploying transactional tables

After importing your transactional data, you add the transactional tables to your system build.

To add transactional tables to your system:

1. Go to **System Builds**.
2. Expand the option menu on your system and select **Edit**.
3. Select the **\+** where you want to add your table in the hierarchy.
4. If the **\+** was above another table, then decide whether to add your transactional table above or next to that table.
5. Select your transactional table from the list.

   > **Note**
   >
   > Orbit understands the table relationships and adds any child tables automatically.
6. Select **Save**.
7. Select **Build** and deploy when complete.

The transactional tables appear in your system with their defined relationships to individuals and parent transactional tables.
