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

Home -> Community -> Usenet -> c.d.o.server -> Re: Uknown query

Re: Uknown query

From: DA Morgan <damorgan_at_psoug.org>
Date: Sat, 30 Dec 2006 12:25:59 -0800
Message-ID: <1167510352.821964@bubbleator.drizzle.com>


calberto2312_at_gmail.com wrote:
> Hi all,
>
> In my statspack reports, I´ve been seeing some similar queries that
> are unknown for me. They are being executed hundreds of times, but I
> want to find out who is running them. Here´s one of the queries :
>
> select a.default_cpu_cost, a.default_io_cost
> from association$ a
> where a.obj# = :1
> and a.property = :2
>
> Can you help me?
>
> Thanks in advanced,
> Carlos

In addition to Jonathan's comments ... here a demo of how you might track down the answer to the "who ran it" question.

Open two SQL*Plus sessions and in session 1:

SQL> uwclass/uwclass

SQL> SELECT /* This is a test */ COUNT(*) FROM airplanes;

and in session 2:

SQL> SELECT parsing_user_id, parsing_schema_id 2 FROM gv$sql
3 WHERE sql_text LIKE '%This is a test%';

HTH

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org
Received on Sat Dec 30 2006 - 14:25:59 CST

Original text of this message

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