<-----Google Analytics Code Start----> <-----Google Analytics Code Close---->
Skip to content

Green

color

Default screen resolution  Wide screen resolution  Increase font size  Decrease font size  Default font size  Skip to content Default color Pink color Green color Green color
Home arrow Technical Articles arrow Miscellaneous Technology arrow Concurrent Programs in Oracle Apps
This website has now moved to http://apps2fusion.com





Concurrent Programs in Oracle Apps | Print |  E-mail
Written by Anil Passi   
Wednesday, 25 October 2006
An article on very basics of Concurrent Program, for beginners that follow http://getappstraining.blogspot.com.

Lets first discuss the below scenario

Being a developer, you have just developed a SQL script or a PL/SQL package procedure. The end user wants to be able to run this script ad-hoc or they wish to schedule this to run every night.

Question : How can an end-user be given control to run a script developed by a developer, given that an end user will never have access to apps password(and rightly so)?
Answer: This script can be attached to a Concurrent Program via a concurrent program executable. The user will then be given access to this Concurrent Program.

Question : But how will the end user or Oracle Apps make this script run every 10hours daily?
Answer : A concurrent program can be scheduled to run at desired intervals. The schedule is defined at the time of submission.

Question: What are the different types of scripts/programs that can be attached to concurrent programs?
Answer :
A sql script
A Sql*Loader program
Java program
Oracle Report
Pl/SQL program ( or call it a stored procedure/package procedure)
Host script, like a unix shell script
Pro*C/Spawned
Perl

Question: What are the basic steps when defining a concurrent program.
Answer: Broadly speaking there are three steps when developing a concurrent program in Oracle Apps
Step 1. Make Oracle Apps identify the executable
Step 2. Provide a handle to the executable by means of defining a concurrent program
Step 3. Make this concurrent program accesible to selected users via their responsibility.

Question: Please can you describe the above steps in detail
Answer:
Step 1. Make Oracle Apps identify the executable
In Oracle Apps we have something called as concurrent program executable. Concurrent program executable is defined to register a script or a procedure for its usage within oracle apps.

Step 2. Provide a handle to the executable by means of defining a Concurrent Program.
We need to define a concurrent program and attach that to the executable defined in above step.

Step 3. Make this concurrent program accesible to selected users via their responsibility.
We do this by adding the concurrent program to something called as request group. The request group is either associated with a responsibility or is passed in as a parameter to the function request form function. Don't worry if you do not understand this step, I will be writing a dedicated article to explain this step.


Question : Please explain the steps for defining a pl/sql concurrent program, with screenshots and with almost real life example?
Answer:
1. Create a table and a stored procedure in pl/sql
create table xx_hello_world_tab
(
 message_text VARCHAR2(
100)
,creation_date DATE
) ;

CREATE OR REPLACE PROCEDURE
xx_register_user_prc(errbuf      OUT VARCHAR2,retcode     OUT VARCHAR2) IS
BEGIN
  INSERT INTO xx_hello_world_tab VALUES (
'Hello World' ,SYSDATE);
END xx_register_user_prc;

SELECT * FROM xx_hello_world_tab ;

--Zero records will be returned here


2. Note the two parameters, namely errbuff and retcode
These parameters for used for the interaction between the concurrent program and the pl/sql Program. I suggest to the beginners not to spend much time on these parameters.

3. Define an executable attached to this procedure.
This can be done by navigating to the responsibility “Application Developer”, and selecting the menu /Concurrent/Executable
Image

4. Define the concurrent program
This can be done by navigating to responsibility “Application Developer” and then selecting menu /Concurrent/Program
Image

5. Attach this program to a report group.
Go to System Administrator responsibility, and select
/Security/Responsibility/Request
Image


Now, we can navigate to the Receivables Manager and submit the concurrent request.
Image

After the completion of the request, we check the table
Image
Comments (54)add
...
written by venkat , October 26, 2006
i have a question. is it enough if we write a
procedure xx_register_user_prc in apps schema and compile it or should i add it to any direcotry like AR_TOP/sql and then register it as a concurrent program
...
written by venkat , October 26, 2006
i have a question. is it enough if we write a
procedure xx_register_user_prc in apps schema and compile it or should i add it to any direcotry like AR_TOP/sql and then register it as a concurrent program
...
written by Anil Passi , November 15, 2006
Hi there,

you can schedule a concurrent request, so that you do not have to execute it manually.

If you want this done programmatically, then use api FND_REQUEST.SUBMIT_REQUEST

Thanks
anil
...
written by Cherry , November 15, 2006
Is there any existing APIs which can call and submit these kinds of requests or concurrent program? The purpose behind is to skip manual submission. I want to trigger some fixed procedure in the backgroud to reduce human workload.
Otherwise, any suggestion?
...
written by Cherry , November 15, 2006
Thanks for your fast response.
Then, Can I call the OFA packages such as AutoCreate PO by writting a PL/SQL as a request in this case?
Is there any existing APIs which allow to do so?
Is it ok to call OFA packages directly? Any concern?

(sorry for too much questions, I am new to Oracle and OFA)

Thanks in advanced.
Cherry
...
written by Anil Passi , November 15, 2006
Hi there,

you can schedule a concurrent request, so that you do not have to execute it manually.

If you want this done programmatically, then use api FND_REQUEST.SUBMIT_REQUEST

Thanks
anil
...
written by Cherry , November 15, 2006
Is there any existing APIs which can call and submit these kinds of requests or concurrent program? The purpose behind is to skip manual submission. I want to trigger some fixed procedure in the backgroud to reduce human workload.
Otherwise, any suggestion?
...
written by Cherry , November 15, 2006
Thanks for your fast response.
Then, Can I call the OFA packages such as AutoCreate PO by writting a PL/SQL as a request in this case?
Is there any existing APIs which allow to do so?
Is it ok to call OFA packages directly? Any concern?

(sorry for too much questions, I am new to Oracle and OFA)

Thanks in advanced.
Cherry
...
written by Eugene , November 18, 2006
Anil,
Great site. I very new to Oracle Apps and learning a whole lot from it.
I have a question about concurrent program. We outsourced an implementation team for Oracle Financials and they told me that I have to generate text files with PO, Receipts, Items, .... data it them (Prod d/b on Windows). Then generated files need to be moved to the server where Financials installed (Linux sever).
Then, they said, the concurrent program will run to load moved files into Apps.
My question is: could I just add a call (via d/b link) to the package on prod server to generate files and move them to the apps server and then proceed with loading files? It seems to me that it would be a completed task. Your thoughts?
Thank you,
Eugene
...
written by Eugene , November 18, 2006
Anil,
Great site. I very new to Oracle Apps and learning a whole lot from it.
I have a question about concurrent program. We outsourced an implementation team for Oracle Financials and they told me that I have to generate text files with PO, Receipts, Items, .... data it them (Prod d/b on Windows). Then generated files need to be moved to the server where Financials installed (Linux sever).
Then, they said, the concurrent program will run to load moved files into Apps.
My question is: could I just add a call (via d/b link) to the package on prod server to generate files and move them to the apps server and then proceed with loading files? It seems to me that it would be a completed task. Your thoughts?
Thank you,
Eugene
...
written by Anil Passi , November 19, 2006
Hi Eugene

I assume the following:-
-----------------------
1. You have some concurrent program definitions to be moved from one environment to another.
2. You wish to add a DB link from Prod box to a development box, so that those definitions can be accessed.

Assuming that I understood your qns correctly:-
1. I guess your outsourcing company is using FNDLOAD to download the concurrent program definitions.
FNDLOAD is described here
http://oracle.anilpassi.com/oracle-fndload-script-examples.html

FNDLOAD creates text files, that can be uploaded in a new environment.

2. You usually never create DB Links frm PRD to DEV environment.
The FNDLOAD link shows how to upload the program definitions too. You do not necessarily need to run a concurrent program, although FNDLOAD command also happens to be an executable of conc program itself.

Thanks,
Anil Passi
...
written by Anil Passi , November 19, 2006
Hi Eugene

I assume the following:-
-----------------------
1. You have some concurrent program definitions to be moved from one environment to another.
2. You wish to add a DB link from Prod box to a development box, so that those definitions can be accessed.

Assuming that I understood your qns correctly:-
1. I guess your outsourcing company is using FNDLOAD to download the concurrent program definitions.
FNDLOAD is described here
http://oracle.anilpassi.com/oracle-fndload-script-examples.html

FNDLOAD creates text files, that can be uploaded in a new environment.

2. You usually never create DB Links frm PRD to DEV environment.
The FNDLOAD link shows how to upload the program definitions too. You do not necessarily need to run a concurrent program, although FNDLOAD command also happens to be an executable of conc program itself.

Thanks,
Anil Passi
...
written by Anil Passi , November 26, 2006
Hi Eugene,

You can certainly do all the steps in one single concurrent program. But for doing so, you need to write a Java Concurrent Program

Thanks
Anil Passi
...
written by Anil Passi , November 26, 2006
Hi Eugene,

You can certainly do all the steps in one single concurrent program. But for doing so, you need to write a Java Concurrent Program

Thanks
Anil Passi
...
written by Hari , November 29, 2006
Hi Anil Passi
I am trying to execute a java program through oracle apps forms. I have created a java concurrent program and I have crated a request and submitted and once its completion I am getting an exception saying that

java.lang.ClassNotFoundException: testOracle.OracleTestProgramNew
at oracle.apps.fnd.cp.request.Run.main(Run.java:117)

I have set the JAVA_TOP and AF_CLASSPATH upto that testOracle parent Directory.

still I am getting the same exception.

could u please sugget me to where I must palce the java class file and its further settings?

Thanks in advance.
HariKrishana.
...
written by Anil Passi , November 29, 2006
Hi Hari

Try to pass the classpath in options field of the concurrent program and try to run it standalone first.

Please note that, DO NOT USE $_TOP notation in classpath when specified from concurrent program options field.

Use notation as below:-

-cp /home/appsborg.zip:/home/xx/java/apps.zip

Put the exact paths and run again, let me know how it goes

thanks
anil passi
...
written by Hari , November 29, 2006
Hi Anil Passi
I am trying to execute a java program through oracle apps forms. I have created a java concurrent program and I have crated a request and submitted and once its completion I am getting an exception saying that

java.lang.ClassNotFoundException: testOracle.OracleTestProgramNew
at oracle.apps.fnd.cp.request.Run.main(Run.java:117)

I have set the JAVA_TOP and AF_CLASSPATH upto that testOracle parent Directory.

still I am getting the same exception.

could u please sugget me to where I must palce the java class file and its further settings?

Thanks in advance.
HariKrishana.
...
written by Anil Passi , November 29, 2006
Hi Hari

Try to pass the classpath in options field of the concurrent program and try to run it standalone first.

Please note that, DO NOT USE $_TOP notation in classpath when specified from concurrent program options field.

Use notation as below:-

-cp /home/appsborg.zip:/home/xx/java/apps.zip

Put the exact paths and run again, let me know how it goes

thanks
anil passi
...
written by Anil Passi , December 18, 2006
Hi Richa,

To crack the interview you first need to crack the fundamentals.

Having said that, I suggest you read all possible articles on this site and also on similar other websites. I think ittoolbox has some very nice articles.

The more you read and understand, the better.

I think http://getappstraining.blogspo...index.html will be a good starting point.

Thanks,
Anil Passi
...
written by Anil Passi , December 18, 2006
Hi Richa,

To crack the interview you first need to crack the fundamentals.

Having said that, I suggest you read all possible articles on this site and also on similar other websites. I think ittoolbox has some very nice articles.

The more you read and understand, the better.

I think http://getappstraining.blogspo...index.html will be a good starting point.

Thanks,
Anil Passi
...
written by Anil Passi , December 25, 2006
Hi Praveen

You may also have a look at the dedicated article on Request Groups http://oracle.anilpassi.com/in...=27&show=1

Thanks,
AniL Passi
...
written by praveen , December 25, 2006
Thanks a lot Anil for the response, you are a great help...i will try to sort the issue out as per your guidance...
...
written by Anil Passi , December 25, 2006
Hi Praveen

You may also have a look at the dedicated article on Request Groups http://oracle.anilpassi.com/in...=27&show=1

Thanks,
AniL Passi
...
written by praveen , December 25, 2006
Thanks a lot Anil for the response, you are a great help...i will try to sort the issue out as per your guidance...
...
written by raj , January 25, 2007
Hello sunil....
Firstof all thanking u for such valuable information for starters,,i have aquestion..
can u help me how a formfunction in attached to a menu..
thanks
raj
...
written by Anil Passi , January 27, 2007
.
.
.
Hi Raj

Please refer to http://getappstraining.blogspo...their.html

thanks
anil
...
written by User , February 22, 2007
Hi Anil,
I just wanted to know, how to define parameters. What If my program requires 2 input parameters say empno,ename?
plz let me know
...
written by User , February 22, 2007
If user wants to enter Input Parameter values while submitting the concurrent program( say empno, ename), how to define them. Plz let me know
...
written by Anil Passi , March 06, 2007
Hi Soham

To run a Concurrent program from Unix Shell you can use CONCSUB. A search on Metalink or google will give you the syntax.


To run a UNIX shell script as a concurrent program,you need to register this as Host Concurrent Program. Say you register an executable named XXCONC within XXPO Module.

on unix, do

1. cd $XXPO_TOP/bin
2. vi XXCONC.prog and edit and write script and save
3. ln -s $FND_TOP/bin/fndcpesr XXCONC
4. ls -l XXCONC

Thanks
Anil Passi
...
written by Tony , April 18, 2007
Hi Anil,

Want to know the answer to

why do we attach program to a specific application only

Thanks in Advance
...
written by Anil Passi , April 18, 2007
Hi Tony

To find the answer, please see the discussion at bottom part of page
http://getappstraining.blogspot.com/2006/10/oracle-apps-training-index.html

The same question as posted by you has been discussed there.

Thanks
Anil
...
written by Anil Passi , April 20, 2007
Hi new user,

To find the answer, please see the discussion at bottom part of page
http://getappstraining.blogspot.com/2006/10/oracle-apps-training-index.html
The same question as posted by you has been discussed there.

Thanks
Anil
...
written by Ajay , May 02, 2007
Hi Anil,
Can i get anyexample of Perl Concurrent program. I am new to perl.

Regards,
Ajay Kunde
...
written by swati , June 01, 2007
Hi Anil,

I have a requirement to enter list of values in a concurrent program parameter like comma separated values.
Is it possible?

Thanks,
Swati
...
written by Anil Passi , June 20, 2007
Hi Deb

Please do the following

1. Create a new package procedure for conc program
with two out parameters.
2. Register this as executable for conc program
3. Within this new procedure, you can execute POOL_ASSIGNMENT. The last three out variables can be displayed in log file or logged into some tables for error reporting.

Thanks,
Anil Passi
...
written by prem , June 28, 2007
Hi,

What is the differnce between the (Concurrent program) SQL Loader program which is having executable method as Host and the one which is having the executable method as SQL*Loader.
...
written by nagender , August 18, 2007
Hi Mr.Anil,
I am new to oracle apps and I would like to know about the submission of concurrent prog ufrom pl/sql.
I know that fnd_request.submit_request(parameters) helps in this, but i don't know how to use it.
Can u please give the syntax of that parameters and what all should be passed for this API to call the concurrent prog.
Thanks,
Nagender
...
written by nagender , August 18, 2007
Hi Mr.Anil,
I am new to oracle apps and I would like to know about the submission of concurrent prog from pl/sql.
I know that fnd_request.submit_request(parameters) helps in this, but i don't know how to use it.
Can u please give the syntax of that parameters and what all should be passed for this API to call the concurrent prog.
Thanks,
Nagender
...
written by Anil Passi , August 19, 2007
Hi Nagender

Please refer to link
http://scripts4oracle.blogspot...ge_19.html

You will find an example there.

Thanks,
Anil Passi
...
written by Subrata Das , September 05, 2007
Hi Anil,
It is very good initiative from your end. needs more on XML publishers.
...
written by Sandhyakashyap , September 17, 2007
I am unable to see any of the pictures on your site, especially the screen-shots. Any particular reason?
...
written by Anil Passi , September 17, 2007
Hi Sandhya

Are you able to visit http://docs.google.com

Possibly your company URL filters off that URL

Cheers
Anil
...
written by madhu , October 25, 2007
Hi Anil,
Your Article is too Good and its very useful.
Regards
Madhuri
...
written by sai d , October 29, 2007
hi anil,

great post first of all. but i have a question

is it possible for one seeded concurrent program to be the trigger of another custom one without disturbing the seeded program? if yes how? im really confused as to how to do this!
...
written by Anil Passi , October 29, 2007
Sai

Not possible, unless the seeded program calls a user hook API or calls a business event.

Thanks,
Anil Passi
...
written by Samuel Schwartz , November 13, 2007
Hi Anil,

In oracle apps => concurrent requests window we have the option to schedule a request and save the schedule also.
I have a requirement. By using a plsql script I have to create a schedule, attach it to a concurrent request so that it runs periodically. Also I should be able to update and cancel an existing schedule.
I have to create around 4 functions (create schedule, submit request, update schedule and cancel schedule). Can I use fnd_request package routines ? If yes, which ones ?

Pls suggest.

P.S : I tried to use Fnd_Request.Set_Repeat_Options. It creates a default release class on its own and so I am unable to specify a schedule name.

Thanks,
Sam
Concurrent Program
written by hari Kishan , December 04, 2007
While registering the concurrent program we first do the executable concurrent program and then define it . So why we need to give the application name twice in executable and as well as definitions
Registering a concurrent program under Windows
written by Sten Vesterli , January 15, 2008
Under Windows (with MKS Toolkit), you would create the link with
ln %FND_TOP%in ndcpesr.exe XXCONC.exe

NTFS under Windows 2003 server does not support symbolic links
to individual files - that's why it's a hard link. Also remember
to call the link .exe - otherwise, Windows will refuse to
execute it.
...
written by anonymous , January 16, 2008
Hi anil,
I was new to oracle apps.how can i see where all the records are get saved when we save them.plz help me.
...
written by vasavi , January 17, 2008
hi anil,

I was new to oracle apps.how can i see where all the records are get saved when we save them.plz help me.And also plz can u tell me the books which i can refer to make my basics strong in apps.



doucuments or practice dumps fo system administrator Exam
written by Manish Sharad , January 22, 2008
Hi Anil:

Its a good effort from your side, appriciated.
I just want help regarding what is the best documentation or the braindump test questions for the the OCP expert exams, i am planning to appear exam code 1ZO-232 system Admin, for Oracle Business Suite.

Thanks
Best Solutions
written by Shekar Suman , January 23, 2008
This is the best way to learn new things about subject.


...
written by Shekar Suman , January 23, 2008
How to call shell script concurrent program (having one parameter) in another concurrent program
Use of Shortname
written by sreekanth munagala , March 17, 2008
Hai Anil,
I have some queries regarding this article.
In the screen we get while defining executable,
there is one option called SHORTNAME.
Why do we need this SHORTNAME?
what is the difference between executable and execution file name?
You must be logged in to a comment. Please register if you do not have an account yet.

busy