Oracle Customer Hub (UCM) Master Data Management Reference > Configuring Oracle Customer Hub (UCM) Privacy Management >

About Blank Privacy Source Data and History Records


Blank privacy history records might be created in the database because external applications send financial account insert requests to Oracle Customer Hub (UCM). To evaluate financial account and financial account contact's privacy preferences, the external application is required to send a privacy record with the financial account and the financial account contact insert request. The source is captured in Oracle Customer Hub (UCM) Transaction Manager. If there is no privacy preference preselected, the privacy preferences in the source record are empty. This record in the source data and history (SDH) table is considered to be a blank record.

If you do not select the privacy preferences before sending information to the rules engine, then the blank record is captured as history. Even though there is no privacy preference in this history record, the record does have some other values internally, such as a foreign key to its parent record type. There are two reasons why this occurs:

  • S_PRIVACY is a separate table. Creating a financial account (FA) or financial account contact (FAC) does not automatically create a child privacy record.
  • There is no NewRecord action available in the core rules engine to call back Oracle Customer Hub (UCM) to create a new privacy record. A privacy record must be created before sending it to the rules engine even though it is a new Financial Account or Financial Account Contact event.

For these reasons, a empty record exists in the base table and the SDH table. The base table empty record exists for a short period because the rules engine is triggered. However, empty records in the SDH table remain.

If you want to remove these blank records, there are several possible solutions. You must evaluate the situation according to your deployment needs. Removing blank privacy SDH records might affect performance adversely.

One solution is to write a script in the business service, UCM FINCORP Account Source Data and History Service. When the Insert method is called, check the values for some of the required fields in UCM FINCORP Account Privacy Source Data and History, UCM FINCORP Account Contact Privacy Source Data and History. If the values are empty, delete the record. Use the following task to add a script to a business service.

To add a script to a business service

  1. In Siebel Tools, find the business service, UCM FINCORP Account Source Data and History Service.
  2. Right click, and choose Edit Server Script.
  3. In Service_InvokeMethod, add the following script in eScript:

    Program Language = JS

  4. Save and compile the changes.

Example Code to Remove Blank Records

The following script removes blank records.

NOTE:  You might have different criteria for what constitutes a blank record. Modify the following script accordingly.

function Service_InvokeMethod (MethodName, Inputs, Outputs)
{
   if (MethodName == "Insert")
   {
      var oBusObj = TheApplication().GetBusObject("UCM FINCORP Account Source Data and History");
      var oBusCompFAP = oBusObj.GetBusComp("UCM FINCORP Account Privacy Source Data and History");
      var oBusCompFACP = oBusObj.GetBusComp("UCM FINCORP Account Contact Privacy Source Data and History");

      with (oBusCompFAP)
      {
         ClearToQuery();
            ActivateField("Affiliate Flag");
            ActivateField("Nonaffiliate Flag");
            ActivateField("Telemarketing Flag");
            ActivateField("Channel Flag");
            SetSearchSpec("Affiliate Flag", "IS NULL");
            SetSearchSpec("Nonaffiliate Flag", "IS NULL");
            SetSearchSpec("Telemarketing Flag", "IS NULL");
            SetSearchSpec("Channel Flag", "IS NULL");
            ExecuteQuery(ForwardBackward);
            while(FirstRecord())
            {
               DeleteRecord();
               NextSelected();
            }
         }

         with (oBusCompFACP)
         {
            ClearToQuery();
               ActivateField("Affiliate Flag");
               ActivateField("Nonaffiliate Flag");
               ActivateField("Telemarketing Flag");
               ActivateField("Channel Flag");
               SetSearchSpec("Affiliate Flag", "IS NULL");
               SetSearchSpec("Nonaffiliate Flag", "IS NULL");
               SetSearchSpec("Telemarketing Flag", "IS NULL");
               SetSearchSpec("Channel Flag", "IS NULL");
               ExecuteQuery(ForwardBackward);
               while(FirstRecord())
               {
                  DeleteRecord();
                  NextSelected();
               }
         }
      }
   }

Oracle Customer Hub (UCM) Master Data Management Reference Copyright © 2015, Oracle and/or its affiliates. All rights reserved. Legal Notices.