Skip to main content

This article discusses how to use the Clear Items prior to import option within Transaction Lists. This option allows you to clear existing Items before importing new ones.

 

 

Clear Items prior to Import

 

This option allows you to clear Items present in your Transaction List and replace them with Items from the imported data. Once enabled, you have two options to define which Items are deleted from the List. The default setting would be the entire List, the other option is to define a limited scope of Items to be deleted.

 

1. Entire List

 

This option will delete all of the Items within the List and replace them with the Items in the import.

For Transaction Lists with unique identifiers, any List Item not present within the import will be deleted.  Any newly identified Items will be created and Properties will be updated for existing Items.  If an item is not located within the import, it will be deleted along with any associated Properties data.  If a Properties is not included in the import, it will not be updated and will remain on any item still located in the List.

For Transaction Lists without unique identifiers, the List will be deleted completely before the import.  This means any Property data that is not in that List will also be deleted.  The ending result is that your Transaction List will match any Items and Properties located within that import.

For example, if you have a List with five Properties and you import a new data set with only three Properties, the two Properties on the List will be left blank.

 

2. Limited Scope

 

This will update a smaller section of a Transaction List that is defined by Properties of your Transaction List that have a Dimension data type. For example, you might have an updated List of Transactions for a particular product or month and you just want those Items to be replaced and not affect Transactions from other months or products.

When this option is selected, you will need to provide the Scope definition or which Items should be deleted and replaced. When choosing the Scope definition, you will see all List Properties that have a data type of Dimension. When you select a Property, the scope will be defined as all Items found with that particular import.

For example, if you select a Property that uses a Month List, and your Import only contains one Month.  Only Transaction List Items that have that particular Month will be deleted and replaced.  All other Transactions with a different month will be left unchanged.

You can also use multiple Properties to be more granular when identifying which Items of the Transaction List get updated or cleared. When selecting more than one Property, the import configuration will ask you to select a Combination method.

 

Combination Method

This option allows you to specify exactly how Pigment should define the deletion scope when multiple Properties are selected.

  • Any combination. The import will update or clear all Items of your target Transaction List that match any combination of values found in the imported data on the selected Properties.
  • Exact matches. The import will only update or clear all Items of your target Transaction List that exactly match the combination of values found in the imported data.

 

Examples 

In the following examples, we will use the Transaction List below that contains Transaction Items from two different Products (Socks and T-Shirt) and 3 months of data (January, February, and March).

 

Month Product Volume
Jan 25 Socks 34
Jan 25 T-Shirt 12
Feb 25 T-Shirt 44
Feb 25 T-Shirt 55
Feb 25 Socks 36
Mar 25 T-Shirt 7

 

And this is the data for import:

 

Month Product Volume
Jan 25 Socks 100
Feb 25 T-Shirt 200

 

 

1. Entire List

If you choose to delete and replace data using the Entire List option, every single Item within this List will be deleted and replaced with only Items from your import.

All Items will be replaced regardless of unique identifier. The Properties of the Transaction List will be affected differently depending on if there is a unique identifier.

If there is no unique identifier in the List, the only Properties that are filled are the ones from the file.

If there is a unique identifier, any Property not in the file would be untouched.

 

Result: The data is exactly the same as the imported data.

 

Month Product Volume
Jan 25 Socks 100
Feb 25 T-Shirt 200

 

 

2. Limited Scope using 1 Property

Scope: 1 Property (Month)

 

In the imported data, two months are detected: Jan 25 and Feb 25. The import will update or clear all Items where the Month matches either value.

 

Result:

 

Month Product Volume
Jan 25 Socks 100
Feb 25 T-Shirt 200
Mar 25 T-Shirt 7

 

 

3.  Limited scope using 2 Properties and “Any Combination” Combination method

Scope: 2 Properties (Month and Product)

Combination method: Any Combination

 

In the imported data, two values are detected for Month (Jan 25 and Feb 25) and two for Product (Socks and T-Shirt). With Any combination, the import will affect any item in your Transaction List where Month and Product match these values. Specifically, this includes Items where:

  • Month is Jan 25 or Feb 25
  • Product is Socks or T-Shirt

 

The Transaction List after the import will be:

 

Month Product Volume
Jan 25 Socks 100
Feb 25 T-Shirt 200
Mar 25 T-Shirt 7

 

 

4.  Limited scope using 2 Properties and “Exact Matches” Combination method

Scope: 2 Properties (Month and Product)

Combination Method: Exact Matches

 

In the imported data, two specific combinations of Month and Product are found: (Jan 25; Socks) and (Feb 25; T-Shirt). With Exact Matches, the import will impact only the Items in your Transaction List that exactly match one of these combinations.

 

The Transaction List after the import will be:

 

Month Product Volume
Jan 25 Socks 100
Jan 25 T-Shirt 12
Feb 25 T-Shirt 200
Feb 25 Socks 36
Mar 25 T-Shirt 7