Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: SQL script to see all concurrents

Re: SQL script to see all concurrents

From: <apogeusistemas_at_gmail.com>
Date: 20 Sep 2006 16:19:35 -0700
Message-ID: <1158794375.291299.266030@i42g2000cwa.googlegroups.com>

DA Morgan wrote:
> apogeusistemas_at_gmail.com wrote:
> > Please, I'm looking for a SQL script to see all concurrents
> > (running, pending and completion) in my Oracle system.
> > regards.
>
> If you are referring to jobs, you don't say, look in DBMS_JOBS.
>
> In future posts please provide sufficient information for us to
> know what you are doing an in what version you are doing it.
> --
> Daniel Morgan
> University of Washington
> Puget Sound Oracle Users Group

Running this script that I got in a site works fine to me, I only need final jobs status. How enable it ?

set echo off
set feedback off
set linesize 97
set verify off

col request_id format 9999999999    heading "Request ID"
     col exec_time format 999999999 heading "Exec Time|(Minutes)"
    col start_date format a10       heading "Start Date"
     col conc_prog format a20       heading "Conc Program Name"
col user_conc_prog format a40 trunc heading "User Program Name"
spool long_running_cr.lst
SELECT
   fcr.request_id request_id,

TRUNC(((fcr.actual_completion_date-fcr.actual_start_date)/(1/24))*60) exec_time,

   fcr.actual_start_date start_date,
   fcp.concurrent_program_name conc_prog,    fcpt.user_concurrent_program_name user_conc_prog FROM

  fnd_concurrent_programs fcp,
  fnd_concurrent_programs_tl fcpt,
  fnd_concurrent_requests fcr

WHERE TRUNC(((fcr.actual_completion_date-fcr.actual_start_date)/(1/24))*60) > NVL('&min',45)
and

   fcr.concurrent_program_id = fcp.concurrent_program_id and

   fcr.program_application_id = fcp.application_id and

   fcr.concurrent_program_id = fcpt.concurrent_program_id and

   fcr.program_application_id = fcpt.application_id and

   fcpt.language = USERENV('Lang')
ORDER BY TRUNC(((fcr.actual_completion_date-fcr.actual_start_date)/(1/24))*60) desc;

spool off

 Request ID (Minutes) Start Date Conc Program Name User Program Name

----------- ---------- ---------- --------------------
--------------------------------------
    1445627        218 01-SEP-02  MWCRMRGA             Margin Analysis
Report(COGS Breakups)
     444965        211 03-JUL-01  CSTRBICR5G           Cost Rollup - No
Report GUI

Thanks Received on Wed Sep 20 2006 - 18:19:35 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US