Oracle Workflow
Topics Covered:
1- Download Workflow Setup File.
2- Workflow Error after Installation.
3- Workflow creation with different conditions.
1- Link to download the Workflow setup file:
http://www.oracle.com/technetwork/database/options/winclient-101059.html
2- For Worfklow error after its installation
+1300: Could not load.+
+1114: Could not load from database.+
+1101: Could not load item types from database. FILTER=%+
+333: Could not set item type properties for 'IBYOPCC'.+
+332: 'SET' validation failed for item type 'IBYOPCC'.+
+306: Invalid display name 'Tarjeta de Crédito/Tarjeta de Compra de Operaciones de iPayment '.+
+203: Value contains leading or trailing spaces.+
The Solution is:
1- update WF_ITEM_TYPES_TL set DISPLAY_NAME = RTRIM(DISPLAY_NAME);
2- update WF_ITEM_TYPES_TL set DESCRIPTION = RTRIM(DESCRIPTION);
3-Always set the nls parameter in the reqistry editor for workflow
AMERICAN_AMERICA.AR8MSWIN1256
1- Basic Workflow Creation:
1- Download Workflow Setup File.
2- Workflow Error after Installation.
3- Workflow creation with different conditions.
1- Link to download the Workflow setup file:
http://www.oracle.com/technetwork/database/options/winclient-101059.html
2- For Worfklow error after its installation
+1300: Could not load.+
+1114: Could not load from database.+
+1101: Could not load item types from database. FILTER=%+
+333: Could not set item type properties for 'IBYOPCC'.+
+332: 'SET' validation failed for item type 'IBYOPCC'.+
+306: Invalid display name 'Tarjeta de Crédito/Tarjeta de Compra de Operaciones de iPayment '.+
+203: Value contains leading or trailing spaces.+
The Solution is:
1- update WF_ITEM_TYPES_TL set DISPLAY_NAME = RTRIM(DISPLAY_NAME);
2- update WF_ITEM_TYPES_TL set DESCRIPTION = RTRIM(DESCRIPTION);
3-Always set the nls parameter in the reqistry editor for workflow
AMERICAN_AMERICA.AR8MSWIN1256
1- Basic Workflow Creation:
2- Workflow with Approve or Reject:
http://www.youtube.com/watch?v=Wkre2JjeYfQ&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=2
3- Workflow with Approve & Reject Notification:
http://www.youtube.com/watch?v=UGeCf4rQi5I&index=2&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
4- Initiate Workflow from Toad:
http://www.youtube.com/watch?v=diz_bOaDG_c&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
Code to run it from toad.
1- First create a sequence.
Create sequence xxTESTSEQ start with 10 increment by 1;
2- Create a plsql block to run the workflow.
begin
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
/
5- Creating attributes and running workflow in oracle apps:
http://www.youtube.com/watch?v=f2GZdyJqfkc&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
6- Workflow with attributes, running from sql:
http://www.youtube.com/watch?v=Yb4TKW9FHeU&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
Procedure to run it from toad or sql;
begin
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTAPPROVER',
avalue => 'MATLOOB');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTINITIATOR',
avalue => 'SYSADMIN');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
7- Running Workflow from plsql with attribute in message as dynamic value:
http://www.youtube.com/watch?v=eIawpsUbWK0&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
8- Worfklow running by plsql more dynamically.
http://www.youtube.com/watch?v=Xy8QVnUkOkk&index=8&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&spfreload=1
Step 1: Create Table to hold dummy data of leaves
create table xx_lvwf_appr_tab (name varchar2(30), mgr varchar2(30), leave_bal number);
insert into xx_lvwf_appr_tab values ('MATLOOB','SYSADMIN',20);
insert into xx_lvwf_appr_tab values ('USER1','MATLOOB',20);
insert into xx_lvwf_appr_tab values ('USER2','MATLOOB',20);
insert into xx_lvwf_appr_tab values ('USER3','SYSADMIN',20);
COMMIT;
Step 2: Create Apps session in Toad
begin
FND_GLOBAL.apps_initialize(user_id =>1654,
resp_id =>20434,
resp_appl_id =>101);
end;
Step 3: Run the block to run the process
declare
x_initiator varchar2(30);
x_mgr varchar2(30);
begin
select user_name into x_initiator from fnd_user
where user_id =FND_PROFILE.VALUE('user_id');
select mgr into x_mgr from xx_lvwf_appr_tab where name = x_initiator;
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTAPPROVER',
avalue => 'MATLOOB');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTINITIATOR',
avalue => 'SYSADMIN');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
9- Workflow with function:
http://www.youtube.com/watch?v=5LYDvpgUHxk&index=9&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
10- Adding another function:
http://www.youtube.com/watch?v=9lYdrGxrJRE&index=10&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
3- Workflow with Approve & Reject Notification:
http://www.youtube.com/watch?v=UGeCf4rQi5I&index=2&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
4- Initiate Workflow from Toad:
http://www.youtube.com/watch?v=diz_bOaDG_c&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
Code to run it from toad.
1- First create a sequence.
Create sequence xxTESTSEQ start with 10 increment by 1;
2- Create a plsql block to run the workflow.
begin
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
/
5- Creating attributes and running workflow in oracle apps:
http://www.youtube.com/watch?v=f2GZdyJqfkc&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
6- Workflow with attributes, running from sql:
http://www.youtube.com/watch?v=Yb4TKW9FHeU&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
Procedure to run it from toad or sql;
begin
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTAPPROVER',
avalue => 'MATLOOB');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTINITIATOR',
avalue => 'SYSADMIN');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
7- Running Workflow from plsql with attribute in message as dynamic value:
http://www.youtube.com/watch?v=eIawpsUbWK0&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&index=4
8- Worfklow running by plsql more dynamically.
http://www.youtube.com/watch?v=Xy8QVnUkOkk&index=8&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER&spfreload=1
Step 1: Create Table to hold dummy data of leaves
create table xx_lvwf_appr_tab (name varchar2(30), mgr varchar2(30), leave_bal number);
insert into xx_lvwf_appr_tab values ('MATLOOB','SYSADMIN',20);
insert into xx_lvwf_appr_tab values ('USER1','MATLOOB',20);
insert into xx_lvwf_appr_tab values ('USER2','MATLOOB',20);
insert into xx_lvwf_appr_tab values ('USER3','SYSADMIN',20);
COMMIT;
Step 2: Create Apps session in Toad
begin
FND_GLOBAL.apps_initialize(user_id =>1654,
resp_id =>20434,
resp_appl_id =>101);
end;
Step 3: Run the block to run the process
declare
x_initiator varchar2(30);
x_mgr varchar2(30);
begin
select user_name into x_initiator from fnd_user
where user_id =FND_PROFILE.VALUE('user_id');
select mgr into x_mgr from xx_lvwf_appr_tab where name = x_initiator;
wf_engine.createprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.nextval,
process => 'TESTPROC');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTAPPROVER',
avalue => 'MATLOOB');
wf_engine.setitemattrtext(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.currval,
aname => 'ATTINITIATOR',
avalue => 'SYSADMIN');
wf_engine.startprocess(itemtype => 'TESTWF',
itemkey => xxTESTSEQ.CURRVAL);
commit;
end;
9- Workflow with function:
http://www.youtube.com/watch?v=5LYDvpgUHxk&index=9&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
10- Adding another function:
http://www.youtube.com/watch?v=9lYdrGxrJRE&index=10&list=PLUbvcYGBBSd6Ta9EsrJ20ffxEXySqEIER
No comments:
Post a Comment