SET LINESIZE 132;
--
COLUMN request_id HEADING 'Request ID' FORMAT 99999999;
COLUMN strttime HEADING 'Start|Time' FORMAT A17;
COLUMN endtime HEADING 'End|Time' FORMAT A17;
COLUMN rtime HEADING 'Elapsed|(Min)' FORMAT 9990.99;
SELECT REQUEST_ID,
TO_CHAR(ACTUAL_START_DATE,'MM/DD/YY HH:MI:SS') strttime,
TO_CHAR(ACTUAL_COMPLETION_DATE,'MM/DD/YY HH:MI:SS') endtime,
-- ACTUAL_COMPLETION_DATE - ACTUAL_START_DATE time,
-- TO_NUMBER(TO_CHAR(ACTUAL_COMPLETION_DATE,'JSSSSS') ) - TO_NUMBER(TO_CHAR(ACTUAL_START_DATE,'JSSSSS')) seconds,
ROUND((ACTUAL_COMPLETION_DATE - ACTUAL_START_DATE)*(60*24),2) rtime,
OUTCOME_CODE,
SUBSTR(completion_text,1,20) compl_txt
FROM fnd_concurrent_requests
-- WHERE TO_NUMBER(TO_CHAR(ACTUAL_COMPLETION_DATE,'JSSSSS') ) - TO_NUMBER(TO_CHAR(ACTUAL_START_DATE,'JSSSSS')) > 3600
-- WHERE ACTUAL_COMPLETION_DATE - ACTUAL_START_DATE > 0.01
WHERE ACTUAL_START_DATE > sysdate-10
ORDER BY 2
/