/* - Time taken by each script/pls code in a Patch..---*/

select TRUNC(t.ELAPSED_TIME * 24 * 60 * 60) SECONDS,
t.PROGRAM_RUN_ID,
t.job_name,
t.product,
t.worker_id,
t.phase,
t.phase_name,
t.arguments,
t.start_time,
t.end_time,
t.subdirectory,
t.command
from applsys.AD_PROGRAM_RUN_TASK_JOBS t
WHERE PROGRAM_RUN_ID in
(select program_run_id
from AD_PATCH_RUNS
where patch_top like '<fulpath_of_patch_location>')
ORDER BY ELAPSED_TIME DESC;