Workflow Triggers Created with 'OR' Logic (Doc ID 507665.1)

Last updated on AUGUST 08, 2017

Applies to:

Siebel Workflow - Version 7.8 [19038] and later
All Platforms

Symptoms

We are seeing all of our workflow triggers being created with the 'OR' logic instead of the bookshelf noted 'AND' logic.

Here is an example:

We have a workflow policy set on the Asset object with the following two conditions:
Asset Number = 12345
Asset Serial Number <> 123456789

When generating triggers, the following is produced:

   create or replace trigger SIEBEL.S_ASSET_ESCL_T1
      after update on SIEBEL.S_ASSET
     for each row
   declare
      "b1-Z026M" boolean := FALSE;
   begin
   if updating('ASSET_NUM') and
      (:new.ASSET_NUM = '12345' or :old.ASSET_NUM = '12345') then
      "b1-Z026M" := TRUE;
   end if;
   if updating('SERIAL_NUM') and
      (:new.SERIAL_NUM <> '123456789' or :old.SERIAL_NUM <> '123456789') then
      "b1-Z026M" := TRUE;
   end if;
   if "b1-Z026M" = TRUE then
   insert into SIEBEL.S_ESCL_REQ (REQ_ID, BT_ROW_ID, RULE_ID, TBL_NAME, CREATED_BY, GROUP_ID)
      values (S_ESCL_REQ_S.nextval, :new.ROW_ID, '1-Z026M',
              'S_ASSET', :new.LAST_UPD_BY, '0VC-W7KI');
   end if;
   end;
/

The two conditions are being 'OR'ed together, rather than 'AND'ed. This is causing lots of escalation records being created on some of our objects.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms