Article

Erasing customer data in Pega Platform 7.4 and earlier

In Pega Platform 7.4 and earlier, you can run an activity to erase customer data. For Pega Platform 7.3 and 7.4, you can download a ruleset that contains the activity from Pega Exchange. For earlier Pega Platform versions, you need to manually create the activity.

  1. Optional: Downloading the PegaCustomerDataPrivacy ruleset
  2. Optional: Creating an activity to erase customer data
  3. Running the activity to erase customer data
  4. Optional: Erasing additional customer data from Pega Marketing applications

Optional: Downloading the PegaCustomerDataPrivacy ruleset

The PegaCustomerDataPrivacy ruleset contains predefined activities that help you to manage customer data for objectives such as regulatory compliance. For Pega Platform 7.3 and 7.4, you can download the ruleset from Pega Exchange and import it into your application.

The ruleset is available on Pega Exchange for Pega Platform 7.3 and 7.4. If you are using an older version of Pega Platform, see Optional: Creating an activity to erase customer data. Pega Infinity contains the ruleset by default, so you do not need to download it.
  1. Download the component Pega GDPR Compliance for Decisioning and Marketing from Pega Exchange. This component contains the PegaCustomerDataPrivacy ruleset.
  2. Log in to your application as an administrator.
  3. Click Designer Studio > Application > Distribution > Import.
  4. Follow the import wizard and import the PegaCustomerDataPrivacy ruleset.
  5. After the import finishes, click App. In the search field of the App Explorer, enter Data-.
  6. Click Technical > Activity, then verify that you can open the activity DeleteCustomerData.

Optional: Creating an activity to erase customer data

For Pega Platform 7.2.1 and 7.2.2, to delete customer data, you must manually create an activity in your application ruleset. For more information about creating custom activities, see About Activities.

The activity that you create must be able to request and then remove data from the following data sets:

pxDecisionResults (Staged Decisions)

For information about requesting data from pxDecisionResults, see Creating an activity to retrieve customer data - pxDecisionResults.

To delete data from pxDecisionResults, configure the activity's Steps page:

  • Method – DataSet-Execute
  • Method Parameters
    • Data Set – pxDecisionResults
    • Operation – Delete by keys
  • Key – pxSubjectID
  • Value – Param.customerId

For an example of this configuration, refer to the following image:

Thumbnail

This allows the activity to delete decision results by using a key, which in this example, is the ID of the customer.

pxInteractionHistory (Interaction History)

For information about requesting data from pxInteractionHistory, see Creating an activity to retrieve customer data - pxInteractionHistory.

To delete Interaction History entries from pxInteractionHistory, use the RDB-Delete method with the following Method Parameters:

  • ClassName – Data-Decision-IH-Fact
  • RequestType – DeleteByCustomerID
  • Access – All
Thumbnail

pxEventStore (Customer Movie)

For information about requesting data from pxEventStore, see Creating an activity to retrieve customer data - pxEventStore.

To delete the Event Summary for a customer, create a data flow.

Thumbnail

Use Event summary as the Abstract shape, and Event store as the Destination shape.

Under Event store > Properties > Save options, set Specify time to live (in seconds) to 1. This means that the events are deleted after one second.

Thumbnail

Running the activity to erase customer data

  1. Log in to Designer Studio.
  2. Search for and open the activity that erases customer data. This can be the activity within the PegaCustomerDataPrivacy ruleset or a custom activity that you created. If you are using the PegaCustomerDataPrivacy ruleset, in the Data- class, the name of the activity is DeleteCustomerData.
    The DeleteCustomerData activity removes all of the data that you collected about the customer. If you want to retain some data, for example, the customer's email address, create a custom activity.
  3. Click Actions > Run.
  4. Enter the ID of the customer whose data you want to erase.

The activity erases the data and returns a .json file with the number of entries that were erased from each data set.

Optional: Erasing additional customer data from Pega Marketing applications

If your environment includes Pega Marketing, you need to erase additional customer data references from your application. Run queries on your database to remove the customer data.

  1. For all versions of Pega Marketing, remove the following data:
    • Contact summary – Delete from MKT_CONTACT_SUMMARY where CUSTOMERID = <<Customer ID>>
    • Subscription management – Delete from MKT_SUBSCRIPTION where CUSTOMERID = <<Customer ID>>
  2. For Pega Marketing 7.31 or later, remove the following data:
    • Email bounce management – Delete from MKT_BOUNCE_DETAILS where CUSTOMERID = <<Customer ID>>
  3. For environments that include Pega Field Marketing, remove the following data:
    • Staging records for Pega Field Marketing campaigns – Delete from MKT_CAMPAIGN_CONTACTS where CUSTOMERID = <<Customer ID>>
  4. Identify all segment tables in your application. Segment tables follow the pattern MKTSEG.
  5. For every segment table, delete references to the customer whose data you want to remove.
    • For Pega Marketing 7.4 – Delete from <<Segment table – MKTSEGxxxx>> where PYSUBJECTID = <<Customer ID>>
    • For Pega Marketing 7.31 or earlier – Delete from <<Segment table – MKTSEGxxxx>> where CUSTOMERID = <<Customer ID>>
    • For Pega Marketing 7.13, 7.21, or 7.22 – also Delete from MKT_DATA_SEGMENT where CUSTOMERID = <<Customer ID>>
Your customers might not exist in all segment tables. If the segment contains no references to the customer, the Delete operation does not remove any rows.

Published August 24, 2018 — Updated August 29, 2018

Related Content

Have a question? Get answers now.

Visit the Pega Support Community to ask questions, engage in discussions, and help others.