Tuesday, March 6, 2012

ORACLE: Find running requests on a server from backend.


ORACLE: Find running requests on a server from backend.


Here is query to check from backend what request are running.
This is general query however you can add parameters to filter the results.

SELECT R.ROWID ROW_ID,
R.REQUEST_ID,
R.PHASE_CODE,
R.STATUS_CODE,
R.PRIORITY_REQUEST_ID,
R.PRIORITY,
R.REQUEST_DATE,
R.REQUESTED_BY,
R.REQUESTED_START_DATE,
R.HOLD_FLAG,
R.HAS_SUB_REQUEST,
R.IS_SUB_REQUEST,
R.UPDATE_PROTECTED,
R.QUEUE_METHOD_CODE,
R.RESPONSIBILITY_APPLICATION_ID,
R.RESPONSIBILITY_ID,
R.SAVE_OUTPUT_FLAG,
R.LAST_UPDATE_DATE,
R.LAST_UPDATED_BY,
R.LAST_UPDATE_LOGIN,
R.PRINTER,
R.PRINT_STYLE,
R.PARENT_REQUEST_ID,
R.CONTROLLING_MANAGER,
R.ACTUAL_START_DATE,
R.ACTUAL_COMPLETION_DATE,
R.COMPLETION_TEXT,
R.ARGUMENT_TEXT,
R.IMPLICIT_CODE,
R.REQUEST_TYPE,
R.PROGRAM_APPLICATION_ID,
R.CONCURRENT_PROGRAM_ID,
PB.CONCURRENT_PROGRAM_NAME PROGRAM_SHORT_NAME,
PB.EXECUTION_METHOD_CODE,
PB.ENABLED_FLAG ENABLED,
DECODE (
R.DESCRIPTION,
NULL,
PT.USER_CONCURRENT_PROGRAM_NAME,
R.DESCRIPTION
|| ' ('
|| PT.USER_CONCURRENT_PROGRAM_NAME
|| ')'
)
PROGRAM,
PB.PRINTER_NAME FCP_PRINTER,
PB.OUTPUT_PRINT_STYLE FCP_PRINT_STYLE,
PB.REQUIRED_STYLE FCP_REQUIRED_STYLE,
U.USER_NAME REQUESTOR,
S.USER_PRINTER_STYLE_NAME USER_PRINT_STYLE,
R.DESCRIPTION DESCRIPTION,
PT.USER_CONCURRENT_PROGRAM_NAME USER_CONCURRENT_PROGRAM_NAME
FROM FND_CONCURRENT_PROGRAMS_TL PT,
FND_CONCURRENT_PROGRAMS PB,
FND_USER U,
FND_PRINTER_STYLES_TL S,
FND_CONCURRENT_REQUESTS R
WHERE PB.APPLICATION_ID = R.PROGRAM_APPLICATION_ID
AND PB.CONCURRENT_PROGRAM_ID = R.CONCURRENT_PROGRAM_ID
AND PB.APPLICATION_ID = PT.APPLICATION_ID
AND PB.CONCURRENT_PROGRAM_ID = PT.CONCURRENT_PROGRAM_ID
AND PT.LANGUAGE = USERENV ('LANG')
AND U.USER_ID = R.REQUESTED_BY
AND S.PRINTER_STYLE_NAME(+) = R.PRINT_STYLE
AND S.LANGUAGE(+) = USERENV ('LANG')

Your feedback/comment is quite important for improving this blog so feel free to leave your comments & suggestions

0 comments:

Post a Comment