• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Techgoeasy

Techgoeasy

Learn Oracle, PHP, HTML,CSS,Perl,UNIX shell scripts

  • Home
  • Oracle
    • Oracle database
    • Oracle Ebusiness Suite
    • Oracle weblogic
    • Oracle Performance Tuning
    • Oracle Hyperion
    • Oracle Cloud Tutorials
  • SQL
  • interview questions
  • Linux
  • PHP and HTML
  • Downloads
  • General
Home » Oracle » Oracle Ebuisness Suite » how to submit workflow background process from backend

how to submit workflow background process from backend

April 18, 2022 by techgoeasy Leave a Comment

Workflow is an important part of Oracle Ebiz Applications In this post, we will check out what is Workflow Background Engine, How to run Workflow Background Process from Unix, How to run Workflow Background Process using SQLPLUS, how to submit workflow background process from backend

Table of Contents

  • What is Workflow Background Engine
  • How to run Workflow Background Process from Unix
  • How to run Workflow Background Process from SQL*Plus
  • how to submit workflow background process from backend
  • how to schedule periodic workflow background process concurrent program from backend

What is Workflow Background Engine

  • The Background Engine is a PLSQL Procedure that checks for and executes any deferred or timed out activities in the workflow system. The arguments of the procedure at the time invoking the procedure determine what all be executed by the Workflow Background process.
  • If new activities are deferred or timed out after the current Background Engine is started, the procedure will check one more time for any new activities to execute before terminating. When all matching activities have been completed, the procedure comes to an end.
  • Workflow Background Engine can be run as a Concurrent program or as a package command on the SQLPLUS command.
  • Let’s check How to run Workflow Background Process using SQLPLUS, how to submit the workflow background process from backend in coming headings

How to run Workflow Background Process from Unix

There is one SQL script placed in $APPL_TOP which can be used to run How to run Workflow Background Process from Unix

$FND_TOP/Admin/Sql/wfbkg.sql

The script will be like

cat workflow_background.sh
sqlplus apps/<apps pass> << EOF
@$FND_TOP/Admin/Sql/wfbkg.sql
exit
EOF

How to run Workflow Background Process from SQL*Plus

We can connect to the apps user and fire the below command

BEGIN
wf_engine.background (itemtype=>NULL ,
process_deferred=>TRUE ,
minthreshold=>NULL ,
maxthreshold=>NULL ,
process_timeout=>FALSE ,
process_stuck=>FALSE);
END;
/
Or
exec wf_engine.background;

how to submit workflow background process from backend

Here is the script which can be used for this purpose for scheduling Workflow background process concurrent Program on 17 Feb 8:20

DECLARE

l_user_name VARCHAR2(240) := 'SYSADMIN';
l_resp_name VARCHAR2(240) := 'System Administrator';

l_user_id       NUMBER;
l_resp_id       NUMBER;
l_resp_appl_id  NUMBER;

l_request_id NUMBER;
BEGIN
-- Apps Initialization
   SELECT    user_id
    INTO l_user_id
   FROM fnd_user
   WHERE user_name =l_user_name;

   SELECT  b.RESPONSIBILITY_ID,b.APPLICATION_ID 
    FROM fnd_responsibility_tl tl, fnd_responsibility b
    WHERE tl.responsibility_name = 'System Administrator'
      AND LANGUAGE=UserEnv('LANG')
      AND tl.RESPONSIBILITY_ID=b.RESPONSIBILITY_ID;

  fnd_global.apps_initialize
    ( user_id => l_user_id
     ,resp_id => l_resp_id
     ,resp_appl_id => l_resp_appl_id
    );
--
l_request_id := FND_request.submit_request(application => 'FND',
                           program     => 'FNDWFBG',   
                           description =>  NULL,
                        start_time  => '2022/02/17 8:20:00',
                        sub_request =>  FALSE,
                           argument1  =>  null, 
                           argument2  =>   null, 
                           argument3  =>  NULL, 
                           argument4  =>   'Y' , 
                           argument5  =>   'N', 
                           argument6  =>   NULL
                           );

                           IF l_request_id> 0 THEN
                            Dbms_Output.put_line(l_request_id);
                            commit;
                           END IF;

END;
?

how to schedule periodic workflow background process concurrent program from backend

Here is the script which can be used for this purpose for scheduling periodic Workfow background process concurrent Program at 16:40 starting at 20 Feb with daily frequency

DECLARE

v_request_id NUMBER;
v_status BOOLEAN;

BEGIN
–Initialize the session with appropirate values
fnd_global.apps_initialize (user_id=>0
,resp_id=>20420
,resp_appl_id=>1);

–Set the Repeat Options
v_status := fnd_request.set_repeat_options ( repeat_interval => 1
, repeat_unit => ‘DAYS’
, repeat_type => ‘START’);
–Submit the Request
v_request_id := FND_request.submit_request(application => ‘FND’,
program => ‘FNDWFBG’,
description => NULL,
start_time => ‘2022/02/20 16:40:00’,
sub_request => FALSE,
argument1 => ‘UMX Login Help’,
argument2 => null,
argument3 => NULL,
argument4 => ‘N’ ,
argument5 => ‘N’,
argument6 => ‘Y’
);
COMMIT;

IF v_request_id = 0 THEN
DBMS_OUTPUT.put_line(‘Request not submitted: ‘|| fnd_message.get);
ELSE
DBMS_OUTPUT.put_line(‘Request submitted successfully. Request id: ‘ || v_request_id);
END IF;

EXCEPTION
WHEN OTHERS THEN
DBMS_OUTPUT.put_line('Exception: ' || SQLERRM);
END;
/

I hope this will help on what is Workflow Background Engine, How to run Workflow Background Process from Unix, How to run Workflow Background Process using SQLPLUS, how to submit workflow background process from backend

Filed Under: Oracle, Oracle Ebuisness Suite

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar



Subscribe to our mailing list

Enter your email address to subscribe to this blog and receive notifications of new posts by email

Recent Posts

  • srvctl commands
  • how to check db size in oracle
  • How to access oracle cloud compute instance(Linux/Window)
  • size of schema in oracle
  • Pagination in Oracle

Copyright © 2022 : TechGoEasy

  • Hire me
  • Privacy Policy
  • Contact Us
  • New? Start Here
  • About Us