AudienceView Connect

Script: Update Customer Marketing Data (AudienceView 6.8.15)

Summary

Script Name Update Customer Marketing Data
Minimum Supported AudienceView Version 6.8.15
Source Type Comma Separated Values (CSV) Single Source
Script Definitions Update Customer Marketing Data

Use Case

The Update Customer Marketing Data script updates the marketing data fields on customer accounts based on a .CSV source file.

AudienceView Configuration Prerequisites

If the fields referenced in the script do not have 'Writable' set to Yes, the script will still run successfully but that data fields will not be updated. For more information, refer to Configuring Marketing Data Fields.
 

Source File Format

This script is run using a single source file.

This source file contains the customer number (or any of three 'Legacy Account Number' fields) to search for the customer to be updated with the marketing data provided. 
Hint
Only single-value customer marketing data fields (i.e. any of the 'data[1-50]', 'currency[1-10]', 'date[1-10]' and 'fixed[1-10]' field) can be included in the source file.
The following image illustrates the structure required for the customermarketing_source_file:

update-customer-marketing_source-6-8-15.jpg

The following table outlines the field mapping:
 
Column Required? Source Column Header AudienceView Field Name UI Field Location
1 Yes
customer
'Customer Number' / 'Legacy Account Number [1-3]'
(Used as a Source Key Column)
Customer Services application Customer|Basic page
2 No data1 Marketing Data 1 Customer Services application Customer|Basic page
3 No data2 Marketing Data 2 Customer Services application Customer|Basic page
4 No fixed1 Fixed Integer 1 Customer Services application Customer|Basic page
5 No date1 Date 1 Customer Services application Customer|Basic page

How the Script Works

The following table outlines the actions and the expected results of the script:
 
Condition Action Expected Results
The customermarketing_source_file provides the 'Customer Number' or any of the 'Legacy  Account Number [1-3]' field under customer column. The script will search for the appropriate customer or legacy account number based on the selection in 'Customer Identifier' execution field. The marketing fields provided in the source file will be updated with the data provided.
The 'Customer Identifier' execution dropdown option selected on the Utilities application Data Management|Schedule page is used to define which value will be used to search for the customer (i.e. 'Customer Number' or any of the 'Legacy  Account Number [1-3]' fields). The values under the customer column in the source file are mapped to 'Customer Identifier' selection and used to update the marketing data. The marketing data fields for the customers are updated with the provided values.
If there is a data3 column in the source file and the value is blank, the existing value in 'data3' field on the customer will be updated with a null value.
The incorrect 'Customer Number' or any of the 'Legacy  Account Number [1-3]' field numbers are provided in source file for column customer The error message, No Customer Found Check value entered for customer, will be displayed. The script will fail for that customer (updating data for the accurate customers).

Creating and Executing the Data Management Job

Script Definition Configuration

The following tables outline the script definition configuration. For more information, refer to General Configuration - Script Definition.
  • Script Definition Name: Update Customer Marketing Data
  • Application Script: Update Customer Marketing Data (text/plain)
Source Section
Source Name Source Type Source Key Column Parent Source Name Parent Key Column
customermarketing_source_file Comma Separated Values customer None None
 
Execution Field Section
Row Field Source Key Column
1 Customer Identifier Name: customer identifier
Label: Customer Identifier
Type: String
Subtype: None
List: customer identifiers
Max # Values: 1
Default Value: Customer Number
Group: None
Display on New Row: Yes
Required: Yes
 

Data Management Configuration

The following outlines the data management job configuration. For more information, refer to Utilities - Data Management.
  • Data Management Job Name: Update Customer Marketing Data
  • Script Definition: Update Customer Marketing Data
The following example creates a job that uses all the available source files of the data management job as it would appear on the Utilities application Data Management|Schedule page:

update-customer-marketing_schedule-6-8-15.jpg