Home
/
Blog
/
Guides
Guides

SFMC Sendable Data Extensions: Primary Keys and Send Relationship

Is Sendable, send relationship, primary key: the three settings that decide whether an SFMC data extension can be sent to, plus the SQL to rebuild a broken one.

You built the audience, the query ran, the rows are there. Then Email Studio refuses to send to it, or Journey Builder will not accept it as an entry source. The cause is almost always the same: the target is not a sendable data extension, or its primary key and send relationship were set up in a way that breaks at send time.

A sendable data extension in SFMC is a data extension with the Is Sendable property on and a send relationship that maps one of its fields to the subscriber key. Add a primary key that is unique, not nullable and has a fixed length, and the data extension will behave in sends, imports, queries and journeys.

‍

This guide covers what sendable actually changes, how to choose the send relationship field, the primary key rules that cannot be undone after creation, a SQL query to rebuild a broken data extension, and the mistakes that surface weeks later as duplicate sends or missing unsubscribes.

‍

What a sendable data extension changes in SFMC

‍

Every data extension is either sendable or non-sendable. Salesforce's own Trailhead puts it simply: sendable data extensions have a send relationship and map to a subscriber, while non-sendable ones hold reference data such as products, orders or store lookups.

The difference is not cosmetic. A send relationship is what lets Marketing Cloud connect a row in your data extension to the All Subscribers list, where subscription status, bounces and unsubscribes are tracked. Without it, the platform has no way to know who the row belongs to.

‍

Is Sendable and Is Testable

When you create a data extension in Email Studio you get two checkboxes. Is Sendable makes the data extension eligible for message sends. Is Testable makes it eligible for test sends, which is what you want for a small QA table of internal addresses that you use with Preview and Test.

‍

When non-sendable is the right choice

Not every table deserves a send relationship. Order lines, product catalogues, store lists and staging tables that only feed a query should stay non-sendable. They are joined in SQL, never sent to directly, and keeping them non-sendable makes that intent visible to the next person who opens Contact Builder.

‍

How the send relationship works

‍

The send relationship is a single setting: you pick a field in the data extension and tell Marketing Cloud that it relates to subscribers on Subscriber Key. The field name does not matter. What matters is that the value in it is the same identifier you use for that person everywhere else in the account.

‍

Pick a stable identifier, not the email address

It is tempting to map EmailAddress to Subscriber Key, and plenty of accounts did. The problem is that email addresses change and one address can be shared by several people. When the address changes, the platform sees a brand new subscriber with no history, and the old one keeps its unsubscribe status while the new one starts clean.

A stable business identifier (a CRM contact ID, a loyalty number, a customer ID from your database of record) avoids that. Salesforce documentation also notes that the subscriber key is stored as a text column even if your IDs are numeric, so create the field as Text and treat it as text in SQL.

‍

One email field, and the subscriber key becomes the contact key

A sendable data extension should contain only one field of type EmailAddress, because that is the field the send uses. And the value you map to Subscriber Key is what the account uses as the contact key in All Contacts, so pick it once and keep it consistent across every sendable data extension, journey entry source and import.

The official Trailhead unit on data extensions is the reference to keep open for this part.

‍

Primary key rules for a sendable data extension

‍

The primary key is a separate decision from the send relationship. The send relationship says which field identifies the subscriber; the primary key says which field (or combination of fields) must be unique per row. On a clean audience table they are the same field, but the platform does not force that.

‍

What the platform enforces

Salesforce documents three hard rules. A primary key must contain a unique value in every row, or a unique combination when several fields are selected. It cannot contain null values, and a text field with no length specified cannot be used as a primary key. In Email Studio that means you set a Length on the field, uncheck Nullable, and check Primary Key.

Then there is the rule people only discover once: primary keys cannot be modified after the data extension is created. You cannot change which fields make up the key through the interface. Get it right at creation, or plan to rebuild. This is also why it helps to generate the SFMC SQL and the target data extension from a plain-language request in one step, rather than patching the key after the fact.

‍

Why the primary key matters for queries and imports

The primary key is also what Update and Append data actions rely on. Salesforce's account optimization guidance states that primary keys are required for imports or queries that do not use the overwrite option, because without a key the platform cannot tell which existing row to update. The same guidance adds one exception: do not put a primary key on triggered send data extensions, since a retry may attempt to write the same record twice.

If you are unsure which data action your query should use, the breakdown in Overwrite vs Update vs Append in SFMC query activities walks through the behaviour of each one against a primary key.

‍

SQL query to rebuild a data extension with the right keys

‍

When a data extension was created without a key, with the wrong key, or without the sendable flag, the fix is to create a new one and copy the data across with a query. Create the new data extension first (sendable, send relationship on SubscriberKey, primary key on the same field), then run this in Automation Studio.

Here is a complete example that also protects you from the most common failure of the copy: duplicate identifiers in the source. In plain language the request is copy Customers_Master into a sendable data extension keyed on CustomerID, keeping the latest row per customer.

SELECT
    x.SubscriberKey,
    x.EmailAddress,
    x.FirstName,
    x.Country
FROM (
    SELECT
        c.CustomerID AS SubscriberKey,
        c.EmailAddress,
        c.FirstName,
        c.Country,
        ROW_NUMBER() OVER (
            PARTITION BY c.CustomerID
            ORDER BY c.ModifiedDate DESC
        ) AS rn
    FROM Customers_Master c
    WHERE c.CustomerID IS NOT NULL
      AND c.EmailAddress IS NOT NULL
) x
WHERE x.rn = 1

Line by line:

  • The outer SELECT lists only the columns that exist in the new target, with SubscriberKey first because it is both the primary key and the send relationship field.
  • The inner SELECT renames CustomerID to SubscriberKey, so the field name in the target matches the role it plays.
  • ROW_NUMBER() partitions by CustomerID and orders by ModifiedDate descending, so the most recent row per customer gets rn = 1.
  • The WHERE clause inside the subquery drops rows with a null identifier or a null email, because neither can be used in a sendable row with a non-nullable key.
  • The outer WHERE keeps only rn = 1, which guarantees uniqueness before the write and avoids a primary key violation.

‍

Target data extension: Customers_Sendable. Primary key: SubscriberKey (Text, length 50, not nullable). Data action: Overwrite for the first load, then Update for daily refreshes once the key is in place.

‍

Checklist: creating a sendable data extension in Email Studio

‍

Run through this before you click Create, because most of it cannot be changed afterwards.

  1. Open Email Studio, go to Subscribers, then Data Extensions, and click Create. Choose Standard Data Extension and Create from New.
  2. Give it a name that follows your convention, set the folder, and check Is Sendable. Check Is Testable only for QA tables.
  3. Decide on retention now if the table is temporary.
  4. Add the identifier field first: Text, length set (50 is enough for most IDs), Primary Key checked, Nullable unchecked.
  5. Add exactly one EmailAddress field, not nullable if the table will be used for email sends.
  6. Add the personalization fields your content needs. Keep names SQL-safe and the total row width reasonable.
  7. Set the Send Relationship: the identifier field relates to subscribers on Subscriber Key.
  8. Create it, then load it with a query whose target is this data extension and whose data action matches the key you just defined.

‍

For step two, the data extension naming convention template gives you a prefix system that separates sendable audiences from reference tables at a glance.

‍

Common mistakes with sendable data extensions and primary keys

‍

Mistakes you cannot undo

Creating the audience table as non-sendable and only noticing when the journey entry source dropdown does not list it. Choosing the email field as the primary key and send relationship, then watching history split every time an address changes. Forgetting the Length on a text field you wanted as the key, which the platform simply refuses.

In all three cases the fix is the rebuild query above: new data extension with the right settings, Overwrite from the old one, then repoint the automation and any journey.

‍

Mistakes that look fine until the send

Mapping the send relationship to a field whose values differ from the subscriber key used elsewhere in the account, so the same person exists twice in All Subscribers and an unsubscribe in one does not suppress the other. Loading a keyed table with Append and expecting duplicates to be skipped rather than the query to fail. Building a journey on a data extension that is not sendable, when Salesforce requires the entry event data extension to be standard and sendable.

For the journey case specifically, how to build a Journey Builder entry source data extension goes through the schedule and the silent failures that follow a bad key.

‍

FAQ

‍

What is a sendable data extension in Salesforce Marketing Cloud?

It is a data extension created with the Is Sendable property and a send relationship that maps one of its fields to the subscriber key. That relationship is what allows Email Studio, Journey Builder and MobileConnect to use the table as an audience and to apply subscription status from All Subscribers.

‍

Can I make an existing data extension sendable?

The sendable property and the primary key are set at creation. In practice the reliable path is to create a new sendable data extension with the correct settings and copy the rows across with a SQL query activity using the Overwrite data action, then update any automation or journey that referenced the old table.

‍

Does the send relationship field have to be the primary key?

No, the platform treats them as separate settings. For an audience table it is still the right design: using the same identifier as both the primary key and the send relationship guarantees one row per subscriber and removes a whole class of duplicate-send issues.

‍

Should I use the email address as the subscriber key?

Only if you have no stable identifier at all. Email addresses change and can be shared, which splits engagement history and subscription status across two subscriber records. A customer ID, CRM contact ID or loyalty number mapped to Subscriber Key is the safer choice.

‍

Why does my query fail with a primary key violation?

The source contains more than one row with the same key value and the target rejects the duplicate. Deduplicate in the query, typically with ROW_NUMBER() partitioned by the key, so that exactly one row per key reaches the target.

‍

Build the sendable data extension and the query in one step with QAiry

‍

Most of the pain above comes from making the right decisions once, before the table exists. QAiry turns a plain-language request into production-ready SFMC SQL and the matching data extension, so the audience is ready to send from the first run instead of being rebuilt after a failed send.

You can install QAiry for free in your own SFMC account or watch the product demos to see how a request becomes a sendable audience.

Share this article
QAiry for SFMC

Skip the SQL. Build segments by chatting.

QAiry turns plain English requests into Salesforce Marketing Cloud audience segments and data extensions — no SQL, no IT ticket, no waiting.

Built for SFMC · ISV Partner · GDPR-ready