Background:
Why Request Set?
To run bunch of concurrent programs sequentially or parallel we use Request Set
Query 1:
Provide Concurrent Program name to the following query.
It lists all the Request Sets which are created with the Concurrent Program given.
SELECT DISTINCT user_request_set_name
FROM FND_REQUEST_SETS_TL
WHERE request_set_id IN
(SELECT request_set_id
FROM FND_REQUEST_SET_PROGRAMS
WHERE concurrent_program_id =
(SELECT CONCURRENT_PROGRAM_ID
FROM fnd_concurrent_programs_tl
WHERE upper(USER_CONCURRENT_PROGRAM_NAME) = upper( '&Enter_Prog_name')));
Query 2:
Provide the Request Set name to the following query.
It lists all concurrent programs of this Request Set.
SELECT USER_CONCURRENT_PROGRAM_NAME
FROM fnd_concurrent_programs_tl
WHERE CONCURRENT_PROGRAM_ID IN
(SELECT concurrent_program_id
FROM FND_REQUEST_SET_PROGRAMS
WHERE request_set_id =
(SELECT request_set_id
FROM FND_REQUEST_SETS_TL
WHERE upper(user_request_set_name) = upper('&Request_Set_Name')));
Why Request Set?
To run bunch of concurrent programs sequentially or parallel we use Request Set
Query 1:
Provide Concurrent Program name to the following query.
It lists all the Request Sets which are created with the Concurrent Program given.
SELECT DISTINCT user_request_set_name
FROM FND_REQUEST_SETS_TL
WHERE request_set_id IN
(SELECT request_set_id
FROM FND_REQUEST_SET_PROGRAMS
WHERE concurrent_program_id =
(SELECT CONCURRENT_PROGRAM_ID
FROM fnd_concurrent_programs_tl
WHERE upper(USER_CONCURRENT_PROGRAM_NAME) = upper( '&Enter_Prog_name')));
Query 2:
Provide the Request Set name to the following query.
It lists all concurrent programs of this Request Set.
SELECT USER_CONCURRENT_PROGRAM_NAME
FROM fnd_concurrent_programs_tl
WHERE CONCURRENT_PROGRAM_ID IN
(SELECT concurrent_program_id
FROM FND_REQUEST_SET_PROGRAMS
WHERE request_set_id =
(SELECT request_set_id
FROM FND_REQUEST_SETS_TL
WHERE upper(user_request_set_name) = upper('&Request_Set_Name')));
Query 3:
Provides the list of programs run under a concurrent request set with its parameters for a concurrent request set request ID.
SELECT fcr.request_id
-- , fcr.description
, fcp.USER_CONCURRENT_PROGRAM_NAME
, fcr.argument1
, fcr.argument2
, fcr.argument3
, fcr.argument4
, fcr.argument5
, fcr.argument_text parameters
FROM fnd_concurrent_requests fcr
, fnd_concurrent_programs_tl fcp
, fnd_lookup_values flv
WHERE 1 = 1
AND TRUNC (fcr.actual_start_date) >= TRUNC (SYSDATE - 360) --Parameter
AND fcr.concurrent_program_id = fcp.concurrent_program_id
AND fcp.language = 'US'
AND flv.language = 'US'
AND flv.lookup_code = fcr.status_code
AND flv.lookup_type = 'CP_STATUS_CODE'
AND flv.start_date_active IS NOT NULL
AND (fcr.request_id IN
(SELECT request_id
FROM fnd_concurrent_requests
WHERE parent_request_id IN
(SELECT request_id
FROM fnd_concurrent_Requests
WHERE parent_request_id = :request_id)))
AND fcp.USER_CONCURRENT_PROGRAM_NAME <> 'Request Set Stage'
ORDER BY request_id;
-- , fcr.description
, fcp.USER_CONCURRENT_PROGRAM_NAME
, fcr.argument1
, fcr.argument2
, fcr.argument3
, fcr.argument4
, fcr.argument5
, fcr.argument_text parameters
FROM fnd_concurrent_requests fcr
, fnd_concurrent_programs_tl fcp
, fnd_lookup_values flv
WHERE 1 = 1
AND TRUNC (fcr.actual_start_date) >= TRUNC (SYSDATE - 360) --Parameter
AND fcr.concurrent_program_id = fcp.concurrent_program_id
AND fcp.language = 'US'
AND flv.language = 'US'
AND flv.lookup_code = fcr.status_code
AND flv.lookup_type = 'CP_STATUS_CODE'
AND flv.start_date_active IS NOT NULL
AND (fcr.request_id IN
(SELECT request_id
FROM fnd_concurrent_requests
WHERE parent_request_id IN
(SELECT request_id
FROM fnd_concurrent_Requests
WHERE parent_request_id = :request_id)))
AND fcp.USER_CONCURRENT_PROGRAM_NAME <> 'Request Set Stage'
ORDER BY request_id;
Query 4:
Concurrent request set all runs
SELECT fcr.request_id
, fcr.description
, TO_CHAR (fcr.actual_start_date, 'DD-MON-RRRR HH24:MI:SS') start_date
, (SELECT fu.user_name
FROM fnd_user fu
WHERE fu.user_id = fcr.requested_by)
user_name
, (SELECT fr.responsibility_name
FROM fnd_responsibility_vl fr
WHERE fr.responsibility_id = fcr.responsibility_id)
responsibility_name
, fcr.completion_text
, fcr.status_code
FROM fnd_concurrent_requests fcr
, fnd_concurrent_programs_tl fcp
, fnd_lookup_values flv
WHERE 1 = 1
AND TRUNC (fcr.actual_start_date) >= TRUNC (SYSDATE - 30) --Parameter
AND fcr.concurrent_program_id = fcp.concurrent_program_id
AND fcp.language = 'US'
AND flv.language = 'US'
AND flv.lookup_code = fcr.status_code
AND flv.lookup_type = 'CP_STATUS_CODE'
AND flv.start_date_active IS NOT NULL
AND UPPER (fcr.description) LIKE UPPER (:request_set) || '%'
ORDER BY fcr.actual_start_date DESC;
, fcr.description
, TO_CHAR (fcr.actual_start_date, 'DD-MON-RRRR HH24:MI:SS') start_date
, (SELECT fu.user_name
FROM fnd_user fu
WHERE fu.user_id = fcr.requested_by)
user_name
, (SELECT fr.responsibility_name
FROM fnd_responsibility_vl fr
WHERE fr.responsibility_id = fcr.responsibility_id)
responsibility_name
, fcr.completion_text
, fcr.status_code
FROM fnd_concurrent_requests fcr
, fnd_concurrent_programs_tl fcp
, fnd_lookup_values flv
WHERE 1 = 1
AND TRUNC (fcr.actual_start_date) >= TRUNC (SYSDATE - 30) --Parameter
AND fcr.concurrent_program_id = fcp.concurrent_program_id
AND fcp.language = 'US'
AND flv.language = 'US'
AND flv.lookup_code = fcr.status_code
AND flv.lookup_type = 'CP_STATUS_CODE'
AND flv.start_date_active IS NOT NULL
AND UPPER (fcr.description) LIKE UPPER (:request_set) || '%'
ORDER BY fcr.actual_start_date DESC;
No comments:
Post a Comment