Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Error code 450 in stored procedure

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
rashmirgowda

New User


Joined: 18 Jun 2008
Posts: 25
Location: india

PostPosted: Thu Dec 02, 2010 6:07 pm    Post subject: Error code 450 in stored procedure
Reply with quote

Hi,

i am using stored procedure in my main module. Main module is calling stored procedure1 and from stored procedure1 its calling stored procedure2.

Stored procedure2 is working fine and return the correct result to stored procedure1 with sqlcode of 450.


Main module --> Sp1 ---> Sp2

Please anyone guide me regarding the same.
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Dec 02, 2010 6:14 pm    Post subject:
Reply with quote

What do you not understand from the SLQCODE -450 Description?
Back to top
View user's profile Send private message
rashmirgowda

New User


Joined: 18 Jun 2008
Posts: 25
Location: india

PostPosted: Thu Dec 02, 2010 6:38 pm    Post subject:
Reply with quote

i Understood that it was some access problem. Please let me know if you have any idea.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Thu Dec 02, 2010 7:54 pm    Post subject:
Reply with quote

My DB2 manual lookup service:
Code:
-450   USER-DEFINED FUNCTION OR STORED PROCEDURE name, PARAMETER NUMBER 
       parmnum, OVERLAYED STORAGE BEYOND ITS DECLARED LENGTH.           
                                                                         
Explanation:  Upon return from a specific function name or a stored     
procedure name, DB2 has detected an overlay storage beyond a parameter's
declared length. The parameter number is specified for a stored procedure
or function. This is not permitted.                                     

It is not an access problem. I suggest you check passed parameters to the stored procedures. One or more may be longer than the length declared in the stored procedure.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Dec 02, 2010 7:57 pm    Post subject:
Reply with quote

I hope you realize that SQLCODE you get was "- 450" and not "450 (without negative sign, as you post in your original post)".

- 450 means -- you've a mismatch in the parameter's declared length and to quote the manual:
Quote:
Upon return from a specific function name or a stored procedure name, DB2 has detected an overlay storage beyond a parameter's declared length. The parameter number is specified for a stored procedure or function. This is not permitted.
Back to top
View user's profile Send private message
rashmirgowda

New User


Joined: 18 Jun 2008
Posts: 25
Location: india

PostPosted: Thu Dec 02, 2010 8:17 pm    Post subject:
Reply with quote

Hi,

i have checked the parameter length. both are same.

Input to storeprocedure1 and output to the stored procedure2 are having same length.

please assist on the same.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Dec 02, 2010 8:18 pm    Post subject:
Reply with quote

You should be making a CALL to DSNTIAR to expand the SQLCA
WHEN EVER YOU ENCOUNTER A NEGATIVE SQLCODE
which will expand your SQLCA contents and provide you with neat bits of info.

Quote:
i have checked the parameter length. both are same.


well excuse me, DB2 must be wrong!
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Thu Dec 02, 2010 8:32 pm    Post subject:
Reply with quote

rashmirgowda wrote:
Hi,

i have checked the parameter length. both are same.

Input to storeprocedure1 and output to the stored procedure2 are having same length.

please assist on the same.

But what perhaps is more interesting, what is the lenght of the actual data passed to stored procedure 1 from your application? Does it exceed the defined parameter lenghts?
Back to top
View user's profile Send private message
rashmirgowda

New User


Joined: 18 Jun 2008
Posts: 25
Location: india

PostPosted: Thu Dec 02, 2010 8:43 pm    Post subject:
Reply with quote

Hi,

From appliaction to stored procedure1 the length of input is 43, output is 66 and inout is 38.

for stored procedure the length of input is 46, output is 3 and inout is 38.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Thu Dec 02, 2010 9:42 pm    Post subject: Reply to: Error core 450 in stored procedure
Reply with quote

You are only looking at the definitions, but what are the length of the actual data supplied when you get the error?
Back to top
View user's profile Send private message
rashmirgowda

New User


Joined: 18 Jun 2008
Posts: 25
Location: india

PostPosted: Fri Dec 03, 2010 5:19 pm    Post subject:
Reply with quote

Hi,

The same length was used and got the error as 450.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Fri Dec 03, 2010 6:08 pm    Post subject:
Reply with quote

OK, if you can't provide further details on the error, this is the end of my help, sorry.

But do try to retrieve the SQLCA information, as dbz suggested above. It will at least tell you what parameter overflowed and in which procedure.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Is the 'prompt' data for the DSLIST p... Willy Jensen TSO/ISPF 1 Tue Dec 06, 2016 4:38 am
No new posts PL/I code tuning/Performance improvement Virendra Shambharkar PL/I & Assembler 3 Mon Dec 05, 2016 11:57 am
No new posts S922 Error yuvan ABENDS & Debugging 3 Fri Dec 02, 2016 6:58 pm
No new posts What is the code in CLIST to enable t... jackzhang75 CLIST & REXX 1 Fri Dec 02, 2016 3:02 am
No new posts IDEAL - Code Retrieval yugendran CA Products 0 Fri Nov 25, 2016 3:27 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us