How to use Aliasing Activities to update Customer Identifiers

How to use Aliasing Activities to update Customer Identifiers

What do I do if a customer updates their identifier?

Alias activities can be used to handle the case when a customer updates their global identifier.
For example:

  • user may update their email to be their work instead of personal
  • user entered the wrong email in a website form

To solve this problem we use an aliasing activity.
An aliasing activity will update a customer's global identifier to a new global identifier.

How do I create an aliasing activity?

You need to create an activity transformation where the:

  • anonymous_customer_id is the old customer value
  • customer is the new customer value

Then under processing config, advanced configuration, check Process as an Aliasing Activity

2118

Example SQL

SELECT 
    u.id as activity_id 
    
    , u.updated_at as ts
    
    , u.email as customer 
    , a.customer  as anonymous_customer_id 
    
    , 'updated_email' as activity 
    
    , NULL as feature_1 
    , NULL as feature_2
    , NULL as feature_3
    
    , NULL as revenue_impact 
    , NULL as link 

from db.users u
left join dw.activity_stream a 
    on (a.activity = 'updated_email' and a.activity_repeated_at is NULL)
 where a.customer is null or a.customer <> u.email




Still have questions?


Our data team is here to help! Here are a couple ways to get in touch...

šŸ’¬ Chat us from within Narrator

šŸ’Œ Email us at [email protected]

šŸ—“ Or schedule a 15-min meeting with our data team