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

# Using Composite Key in NCE

Use this option to create new NCE records when a new primary key and composite key(s) combination is ingested and update the existing records, if the same combination is ingested again.

### When Composite Key Is Enabled

When the **Composite Key** is enabled, Zeotap CDP retains both existing and incoming records in the user profile. This approach is useful when merging customer data and non-customer data using multiple Join Keys. Each time a unique combination of the primary key and composite key(s) is ingested, a new NCE record is created. If the same combination is ingested again, the existing record is updated.

**Example**

A customer (UCID: 12345) has multiple registered phone numbers. The append operation ensures all numbers are retained in the profile instead of replacing existing ones.

| **UCID** | **Phone Number** |
| :------- | :--------------- |
| 12345    | 555-1234         |
| 12345    | 555-5678         |

### When Composite Key Is Disabled

When the **Composite Key** is disabled, Zeotap CDP updates existing records or adds new records based on the Join Key. This approach maintains data consistency and prevents duplication.

**Example**

A customer (UCID: 67890) has multiple subscription plans (family, work, personal). The upsert operation works as follows:

* **Existing records are updated**: If the customer already has a **work plan**, the system updates it with the latest details.
* **New records are added**: If the customer adds a **family plan**, it is added under the same UCID without overwriting other plans.

| **UCID** | **Subscription Plan** | **Status** |
| :------- | :-------------------- | :--------- |
| 67890    | Work Plan             | Updated    |
| 67890    | Family Plan           | Added      |

By selecting the appropriate operation, you can control how data is managed in the user profile.

## Related Topics

<CardGroup>
  <Card title="How to use NCE?" href="/articles/unify-customer/how-to-use-nce" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="Why do we need NCE?" href="/articles/unify-customer/why-do-we-need-nce" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="Understand One-to-Many Relationship in NCE" href="/articles/unify-customer/understand-one-to-many-relationship-in-nce" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="Understand Join Key Enricher and how to configure it" href="/articles/unify-customer/configuring-the-join-key-enricher" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="Create an NCE source for the source types: Flat Files, Server to Server, CRM Data, and Data Warehouse" href="/articles/integrate-customer/creating-a-source" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="How to map NCE data in the Zeotap Catalogue?" href="/articles/unify-customer/map-the-catalogue-for-non-customer-entity-data" icon="angles-right" iconType="solid" horizontal={true} />

  <Card title="How to create an NCE attribute in Zeotap Catalogue?" href="/articles/unify-customer/adding-a-non-customer-entity-category" icon="angles-right" iconType="solid" horizontal={true} />
</CardGroup>
