Appending a Data Extension in Salesforce Marketing Cloud

April 16, 2022

Collecting Supplemental Customer Data on an Existing Data Extension with Smart Capture forms in Salesforce Marketing Cloud

Smart Capture in Salesforce Marketing Cloud can be a handy tool for collecting customer information within your email program. But if you want to take it beyond just entering new subscribers? 

In this scenario, you want to email an existing customer and try to collect additional details. So, how do you append new information onto existing subscriber data using a Smart Capture form?

Build Your Data Extension

One of the most common mistakes by marketers is to send out emails to people without their permission. Don't assume that just because someone attended your event, bought something from you, or performed any other action that they want to get emails from you.

Get clear permission from your audience to deliver quality and relevant emails to them. This can be through a signup form on your website, a check box requesting emails on a paper form, or other methods. The key here is to ask permission instead of asking them to opt out of emails. E.g., don't bury an auto-opt-in message in your customer journey.

When you ask for permission, you increase the number of engaged and interested people in your list. This in turn will increase the number of people who will be likely to open your emails. To start, you’ll want to plan what your form will request from a customer. In my use case, I created a survey with a mixture of radio buttons and open text fields. Your Data Extension will need to have fields available for each question you ask before you build your form.

We’ll use the same Data Extension for our email delivery as for collection. Your DE must include the primary subscriber key, but it can include other identifiers as desired. Simply include the customer data in the DE you’ll be sending from, and include nullable fields for each question in your form:

Once your DE planning and creation above is complete, we will then build a CloudPage and Smart Capture form based on that work.

Build Your Smart Capture form and CloudPage

1. Open Web Studio -> CloudPages

2. Create a Collection (or add to an existing one)

3. Add Content -> Landing Page

4. Name your page and create the URL at the prompt

5. Choose your preferred landing page layout, and Save

6. Drag and drop the Smart Capture button to the page

7. Choose the Data Extension where your nullable fields live. This will populate the attributes information:

8. Check the boxes next to your questions in the order that you wish for them to appear on the smart capture form. Be sure to update the Field Label for each and add your question Options as necessary. 

9. Once your form is built, we’ll need to reference the primary subscriber key from your Data Extension. This is how we tell the form that the customer entering the form is related to existing data.

We do this by using Hidden Attributes. Click “Add Hidden Attribute” and enter your customer id field name as follows, changing ‘CustomerID’ to match your field name:

%%=AttributeValue('CustomerID')=%%

In my database case, it looked as follows because my subscriber key field is called “Contact_ID”: 

10. I recommend sending over both the email and contact ID at a minimum, so add both fields to your Hidden Attributes using the method above.

11. Verify your Submit Options are set up before you save and publish the CloudPage.

12. In your email, your link will not be to the standard CloudPage URL. Instead, we’re going to reference the Page ID. You can find the CloudPage Page ID under the Settings icon for Page Details for your individual page. Keep this Page ID handy for the next step.


Linking to Your Smart Capture Form From Email

Next, we need to create a link within our customer email to both direct them to this CloudPage and tell the page who they are.

In your email link, we’re going to send folks to a code snippet. The base is as follows:


<a href="%%=RedirectTo(CloudPagesURL(####, 'EmailFieldName', @EmailFieldName, 'CustomerIDFieldName', @CustomerIDFieldName))=%%", 'Additional_Field_If_Desired', @ Additional_Field_If_Desired>Your link text here</a>


Once you leverage this link, simply send your email to your Data Extension you used in the first step. Your form will start to collect additional details and send the answers back to that same DE.

Enjoy!