Home » SQL & PL/SQL » SQL & PL/SQL » ORA-24338: statement handle not executed (Oracle 10.2.0.3)
ORA-24338: statement handle not executed [message #397383] Fri, 10 April 2009 07:33 Go to next message
user2004
Messages: 33
Registered: April 2009
Member
Quote:


ORA-24338: statement handle not executed
Cause: A fetch or describe was attempted before executing a statement handle.

Action: Execute a statement and then fetch or describe the data.




A fetch or describe was attempted before executing a statement handle - what does it mean? Can anyone help me out with an example ( by reproucing the error and providing solution).


Thanks in Advance!
Re: ORA-24338: statement handle not executed [message #397387 is a reply to message #397383] Fri, 10 April 2009 07:46 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
A fetch or describe was attempted before executing a statement handle - what does it mean?

You didn't parse the statement.

Regards
Michel
Re: ORA-24338: statement handle not executed [message #397393 is a reply to message #397387] Fri, 10 April 2009 08:20 Go to previous messageGo to next message
user2004
Messages: 33
Registered: April 2009
Member
Thanks for the response
Din't get you! Do I need to each and every line of the procedure?
The procedure contains more than 2k lines of code. Or do i need to check only Open cursor for select ...?
Re: ORA-24338: statement handle not executed [message #397396 is a reply to message #397393] Fri, 10 April 2009 08:48 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I don't understand you.
You posted an error, I explained you why you have it.
Now for your current procedure, I don't know, I haven't it.

Regards
Michel
Re: ORA-24338: statement handle not executed [message #397400 is a reply to message #397396] Fri, 10 April 2009 08:53 Go to previous messageGo to next message
user2004
Messages: 33
Registered: April 2009
Member

I do understand.
The procedure contains more than 2.5 k of lines. Its uses FETCH statement as well as functionname.variable.

Want to know when this occurs with a simple example if you have.
It would help me to understand if u can give me an example reraising the error.
Re: ORA-24338: statement handle not executed [message #397407 is a reply to message #397383] Fri, 10 April 2009 09:09 Go to previous messageGo to next message
BlackSwan
Messages: 25033
Registered: January 2009
Location: SoCal
Senior Member
You need to help us by following the Posting Guidelines as stated below.
http://www.orafaq.com/forum/t/88153/0/
Please, please, please Read & Follow Posting Guidelines above.
Go to the section labeled "Practice" & do as directed.
Re: ORA-24338: statement handle not executed [message #397413 is a reply to message #397400] Fri, 10 April 2009 09:20 Go to previous messageGo to next message
Frank
Messages: 7880
Registered: March 2000
Senior Member
What Michel said "you didn't parse the statement" was referring to your code.
He did not mean you did not show us your statement, but he meant that IN your code you did a fetch without first parsing the statement.
Re: ORA-24338: statement handle not executed [message #397416 is a reply to message #397407] Fri, 10 April 2009 09:26 Go to previous messageGo to next message
user2004
Messages: 33
Registered: April 2009
Member
@Blackswan,
Please for dont reply from your side to my any query.Its a request!!

[ Now dont make it a quote and say others should comply. I am expecting from others but not you. ]



I have mentioned that I need some help to know how this issue is raised.With some simple examples if possible. And for that I dont have to read forum guidelines I belive.


Thanks Michel Sir for the suggesion but also sorry for not being able to paste the proc which contains more than 2500 lines of code. I can understand that without seeing the data its difficult for you to tell where the error is.

I just wanted to know how/when this error is raised with some example if the error can be reproduced.

Thanks in adavance
Re: ORA-24338: statement handle not executed [message #397434 is a reply to message #397416] Fri, 10 April 2009 12:20 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
I don't know if you can get it from PL/SQL procedure but you can get it with an OCI program.
Actually you get it if you don't "execute" between "parse" and "fetch" or "describe", that is if you don't execute the statement (even if you parse it).

Regards
Michel
Re: ORA-24338: statement handle not executed [message #397435 is a reply to message #397434] Fri, 10 April 2009 12:23 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
You can also get it if you fetch again the cusor after rebinding the variables without reexecuting the statement/cursor.

Regards
Michel
Re: ORA-24338: statement handle not executed [message #397518 is a reply to message #397435] Sat, 11 April 2009 13:55 Go to previous message
user2004
Messages: 33
Registered: April 2009
Member
Thanks Michel /Frank Sir, for the advice.

I was able to find the reason for the error. The error raised
as some data should be inserted in a temp table before executing the procedure.



Previous Topic: One year minus on Date
Next Topic: Regarding NEW_TIME
Goto Forum:
  


Current Time: Sat Dec 03 03:58:24 CST 2016

Total time taken to generate the page: 0.07651 seconds