Unix Technical Forum

SQL Experts Apply Within

This is a discussion on SQL Experts Apply Within within the Oracle Database forums, part of the Database Server Software category; --> Hi, I'm seeking some advice. Basically, one of our developers has written an insert-select statement within a procedure. When ...


Go Back   Unix Technical Forum > Database Server Software > Oracle Database

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-24-2008, 05:57 PM
Johne_uk
 
Posts: n/a
Default SQL Experts Apply Within

Hi,

I'm seeking some advice. Basically, one of our developers has written
an insert-select statement within a procedure. When the statement is
extracted from the procedure and run in sqlplus it executes in about 30
secs (populated table).

However, when the procedure itself was executed it was still running 2
days later and then generated a RBS segment too small error. During
this time the session was marked as ACTIVE and no exceptions were
thrown by the procedure.

I can't understand why running the same code in a procedure would make
such a difference.
The problem is definitely not linked to permissions.

Does anybody have any suggestions how I can start diagnosing this..

Thanks in advance.
John

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-24-2008, 05:57 PM
Johne_uk
 
Posts: n/a
Default Re: SQL Experts Apply Within

Sorry mean select-insert statement.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-24-2008, 05:57 PM
Robert Klemme
 
Posts: n/a
Default Re: SQL Experts Apply Within

Johne_uk wrote:
> Sorry mean select-insert statement.


And you're sure it's on the same DB with the same amount of data touched?

robert

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-24-2008, 05:57 PM
DA Morgan
 
Posts: n/a
Default Re: SQL Experts Apply Within

Johne_uk wrote:
> Hi,
>
> I'm seeking some advice. Basically, one of our developers has written
> an insert-select statement within a procedure. When the statement is
> extracted from the procedure and run in sqlplus it executes in about 30
> secs (populated table).
>
> However, when the procedure itself was executed it was still running 2
> days later and then generated a RBS segment too small error. During
> this time the session was marked as ACTIVE and no exceptions were
> thrown by the procedure.
>
> I can't understand why running the same code in a procedure would make
> such a difference.
> The problem is definitely not linked to permissions.
>
> Does anybody have any suggestions how I can start diagnosing this..
>
> Thanks in advance.
> John


It doesn't ... something else is happening. Here's a simple test:

BEGIN
<your_statement_here>;
END;
/

How long does it take to run?

Also ... what version of Oracle and post the explain plan.
--
Daniel A. Morgan
http://www.psoug.org
damorgan@x.washington.edu
(replace x with u to respond)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-24-2008, 05:57 PM
erwiggins@gmail.com
 
Posts: n/a
Default Re: SQL Experts Apply Within

Would you post the PLSQL that wraps this DML statement please? Sounds
like some type of infinite looping, etc. You are getting a ORA-01555
error right (snapshot too old)? Which version of Oracle?

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:38 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com