IBM Support

manageCustomer API does not reset or delete the customer additional addresses

Troubleshooting


Problem

Attempts to run the manageCustomer API throws error YFC0002: Record does not exist in the database in IBM Sterling Order Management.

Symptom

Steps to reproduce:

  1. Create a customer by calling manageCustomer API

    <Customer CustomerID="123456678" CustomerRewardsNo="056487126678"
    CustomerType="02" ExternalCustomerID="E7D6224F-123F-456C-9B9A-53BE9E347523" Operation="Manage" OrganizationCode="DEFAULT"
    RegisteredDate="2018-03-01T12:34:00">
       <CustomerContactList>
           <CustomerContact CustomerContactID="" EmailID="" Status="">
               <CustomerAdditionalAddressList Reset="Y" >
                   <CustomerAdditionalAddress AddressType="" IsBillTo=""  IsDefaultBillTo="" IsDefaultShipTo="" IsShipTo="">
                       <PersonInfo AddressID="" AddressLine1="Street2" AddressLine2="" City=""
                       Country="" DayPhone="" EMailID="ms@gmail.com" FirstName="Mark"
                       LastName="Smith" MiddleName="H" MobilePhone="416-123-3212"
                       OtherPhone="" PreferredShipAddress="N" State="" Title="Mr" ZipCode=""/>
                   </CustomerAdditionalAddress>
               </CustomerAdditionalAddressList>
           </CustomerContact>
       </CustomerContactList>
       <CustomerCurrencyList Reset="Y">
           <CustomerCurrency Currency="CAD" IsDefaultCurrency="Y"/>
       </CustomerCurrencyList>
    </Customer>



  2. Call manageCustomer API with below input to reset or delete the customer additional addresses

    <Customer CustomerID="123456678" CustomerRewardsNo="056487126678"
    CustomerType="02" ExternalCustomerID="E7D6224F-123F-456C-9B9A-53BE9E347523" Operation="Manage" OrganizationCode="DEFAULT"
    RegisteredDate="2018-03-01T12:34:00">
       <CustomerContactList>
           <CustomerContact CustomerContactID="" EmailID="" Status="">
               <CustomerAdditionalAddressList Reset="Y">
                   <CustomerAdditionalAddress AddressType="" IsBillTo="" IsDefaultBillTo="" IsDefaultShipTo="" IsShipTo="" CustomerAdditionalAddressID="100000160" CustomerAdditionalAddressKey="20180410211400300554"
                   Operation="Delete">
                   </CustomerAdditionalAddress>
               </CustomerAdditionalAddressList>
           </CustomerContact>
       </CustomerContactList>
       <CustomerCurrencyList Reset="Y">
           <CustomerCurrency Currency="CAD" IsDefaultCurrency="Y"/>
       </CustomerCurrencyList>
    </Customer>
This results in the error YFC0002: Record does not exist in the database.

Cause

Input to the manageCustomer API for Reset is incorrect.

Resolving The Problem

Reset is being performed for customer additional address list for a customer id but customer contact id is not specified.

Following are the sample input xmls to achieve the desired result.

  • <Customer CustomerID="123456678" CustomerRewardsNo="056487126678"
CustomerType="02" ExternalCustomerID="E7D6224F-123F-456C-9B9A-53BE9E347523" Operation="Manage" OrganizationCode="DEFAULT"
RegisteredDate="2018-03-01T12:34:00">
    <CustomerContactList>
        <CustomerContact CustomerContactID="100000160">
            <CustomerAdditionalAddressList Reset="Y">
            </CustomerAdditionalAddressList>
        </CustomerContact>
    </CustomerContactList>
    <CustomerCurrencyList Reset="Y">
        <CustomerCurrency Currency="CAD" IsDefaultCurrency="Y"/>
    </CustomerCurrencyList>
</Customer>
  • <Customer CustomerID="123456678" CustomerRewardsNo="056487126678"
CustomerType="02" ExternalCustomerID="E7D6224F-123F-456C-9B9A-53BE9E347523" Operation="Manage" OrganizationCode="DEFAULT"
RegisteredDate="2018-03-01T12:34:00">
    <CustomerContactList>
        <CustomerContact CustomerContactID="100000190" EmailID="" Status="">
            <CustomerAdditionalAddressList Reset="N">
                <CustomerAdditionalAddress AddressType="" IsBillTo="" IsDefaultBillTo="" IsDefaultShipTo="" IsShipTo="" CustomerAdditionalAddressID="100000190" CustomerAdditionalAddressKey="20180420153410303081"
                Operation="Delete">
                </CustomerAdditionalAddress>
            </CustomerAdditionalAddressList>
        </CustomerContact>
    </CustomerContactList>
    <CustomerCurrencyList Reset="Y">
        <CustomerCurrency Currency="CAD" IsDefaultCurrency="Y"/>
    </CustomerCurrencyList>
</Customer>

[{"Product":{"code":"SS6PEW","label":"Sterling Order Management"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"--","Platform":[{"code":"PF033","label":"Windows"}],"Version":"9.5","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Document Information

Modified date:
16 June 2018

UID

swg22016533