Saturday, August 16, 2008

Identify concurrent requests using the most system resource.

select fcp.USER_CONCURRENT_PROGRAM_NAME||'^'||count(*)||'^'||trunc(sum(actual_completion_date - actual_start_date)*24)
from fnd_concurrent_programs_tl fcp,
fnd_concurrent_requests fcr
where fcp.concurrent_program_id = fcr.concurrent_program_id
and fcp.language = 'US'
group by fcp.USER_CONCURRENT_PROGRAM_NAME
order by sum(actual_completion_date - actual_start_date)*24 desc;