The following is the Sample Code to Submit the Concurrent Programfrom the backend.
Note:- This is the Concurrent Program, not the RequestSet. To Submit the Request Set from the backend, We have different API.
DECLARE
l_success NUMBER;
BEGIN
BEGIN
fnd_global.apps_initialize( user_id=> 2572694, resp_id => 50407,
-- If you are directlyrunning from the database using the TOAD, SQL-NAVIGATOR or SQL*PLUS etc. Then you need to Initialize the Apps.
-- In thiscase use the above API to Initialize the APPS. If you are using same code insome procedure and running directly fromapplication then you don't need to initalize.
-- Thenyou can comment the above API.
l_success
fnd_request.submit_request
('XXAPP',-- Application Short name of the Concurrent Program.
'
'Program For testing the backendReport', -- Descriptionof the Program.
SYSDATE, --Submitted date. Always give the SYSDATE.
FALSE, --Always give the FLASE.
'1234' --Passing the Value to the First Parameter of the report.
)
COMMIT;
--Note:- In theabove request Run, I have created the Report, which has one parameter.
IFl_success = 0
THEN
-- fnd_file.put_line(fnd_file.LOG, 'Request submission For this store FAILED' );
DBMS_OUTPUT.PUT_LINE('Request submission For this store FAILED' );
ELSE
-- fnd_file.put_line(fnd_file.LOG, 'Request submission for this store SUCCESSFUL');
DBMS_OUTPUT.PUT_LINE('Request submission For this store SUCCESSFUL' );
ENDIF;
--Note:- If you arerunning directly from database, use DBMS API to display.
--If you are running
END;
No comments:
Post a Comment