Home » SQL & PL/SQL » SQL & PL/SQL » Procedure execution issue and trace (11g r2, linux)
Procedure execution issue and trace [message #657352] Mon, 07 November 2016 06:52 Go to next message
qazims92
Messages: 37
Registered: July 2016
Location: Lahore Pakistan
Member
Hi Experts,

I have a procedure which almost works fine but sometimes it fails.

How can I know the reason of failure or what statement in procedure cause failure?

Can tracing provide such info?

Kindly guide.

Regards,
Qazi
Re: Procedure execution issue and trace [message #657353 is a reply to message #657352] Mon, 07 November 2016 06:55 Go to previous messageGo to next message
Littlefoot
Messages: 21807
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
When it fails, how does it fail? Does it raise any exception? If so, which one?
Re: Procedure execution issue and trace [message #657366 is a reply to message #657352] Mon, 07 November 2016 09:34 Go to previous messageGo to next message
pablolee
Messages: 2882
Registered: May 2007
Location: Scotland
Senior Member
In addition to Littefoot's questions:
Under what conditions does it fail?
Re: Procedure execution issue and trace [message #657412 is a reply to message #657366] Tue, 08 November 2016 03:34 Go to previous messageGo to next message
qazims92
Messages: 37
Registered: July 2016
Location: Lahore Pakistan
Member
Thanks Littlefoot and Pablolee for your kind response.
I have as much knowledge about this procdure as I have provided you.

Can we trace steps of procedure execution to know which step was cause of failure? and how?

Regards,
Qazi
Re: Procedure execution issue and trace [message #657413 is a reply to message #657412] Tue, 08 November 2016 03:40 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

If you can modify the code and execute the procedure with SQL*Plus, then you cn add some dbms_output.put_line statements in the code.

Re: Procedure execution issue and trace [message #657414 is a reply to message #657412] Tue, 08 November 2016 03:42 Go to previous messageGo to next message
cookiemonster
Messages: 13920
Registered: September 2008
Location: Rainy Manchester
Senior Member
So you don't know what the code is?
You don't know if it raises an error or not?

If it's raising an error then the error message will tell you which line the error occurred on
Re: Procedure execution issue and trace [message #657415 is a reply to message #657414] Tue, 08 November 2016 03:51 Go to previous messageGo to next message
Roachcoach
Messages: 1576
Registered: May 2010
Location: UK
Senior Member
I'm going in for 5 cents on it having a "when others" line...
Re: Procedure execution issue and trace [message #657416 is a reply to message #657415] Tue, 08 November 2016 03:56 Go to previous message
cookiemonster
Messages: 13920
Registered: September 2008
Location: Rainy Manchester
Senior Member
distinctly possible, I started typing something about that decided to wait and see if the OP will tell us what actual error message he's getting.
Previous Topic: conversion to 16bit decimal
Next Topic: external table with single column
Goto Forum:
  


Current Time: Sat Apr 20 07:38:24 CDT 2024