Determining Whether to Add or Change a Customer

The system uses the following logic to determine whether to add a new customer or change an existing one when it receives an Inbound Customer Message (CWCustomerIn).

Note: The cst_action_type attribute indicates whether the Inbound Customer Message (CWCustomerIn) is an Add or Change request; however, this attribute is informational only and CWSerenade uses the customer information in the message to determine whether to create a new customer or change an existing one.

The system considers an Inbound Customer Message (CWCustomerIn) an Add request if:

• the message does not include a cst_cust_nbr (sold to customer number), cst_interface_cust_nbr (alternate customer number), or cst_relate_id (Relate ID).

• the message includes a cst_relate_id (Relate ID) but no cst_cust_nbr (sold to customer number) and the cst_relate_id does not match an existing customer.

• the message includes a cst_interface_cust_nbr (alternate customer number) but no cst_cust_nbr (sold to customer number) or cst_relate_id (Relate ID) and the cst_interface_cust_nbr does not match an existing customer based on the records in the Customer Sold To Xref table.

See Adding a Customer using the Customer API for processing details. Note: After determining an Inbound Customer Message (CWCustomerIn) is an Add request, the system determines whether the customer information in the Add request matches an existing customer, and based on the cst_duplicate flag in the Add request, may update the existing customer; see Duplicate Checking for Add Requests.

If the Inbound Customer Message (CWCustomerIn) does not meet the requirements for an Add request, the system considers the message a Change request; see Changing a Customer using the Customer API for processing details.

CS03_24 Serenade 5.0 March 2015