How To Cancel Workflow Oracle E-Business Suite?

You can cancel the workflow with the following script as single or multiple.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
DECLARE
   CURSOR aa
   IS
      SELECT item_type, item_key, root_activity
        FROM wf_items wi
       WHERE wi.item_type = :item_type
         AND wi.item_key IN (:item_key1, :item_key2, ...)
         AND wi.end_date IS NULL;
BEGIN
   FOR bb IN aa
   LOOP
      wf_engine.abortprocess(itemtype => bb.item_type, 
                             itemkey => bb.item_key, 
                             process => bb.root_activity);
      COMMIT;
   END LOOP;
END;