IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

SQLCODE 00000031}


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
apandey

New User


Joined: 31 Aug 2009
Posts: 73
Location: Mumbai

PostPosted: Tue May 24, 2011 5:10 pm
Reply with quote

Hi,
Can anyone pls let me value what is value of SQLCODE "00000031}"
I know "}" is EBCDIC code, but i am not able to find its actual value?

Is it -310 ? (It's a guess)
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Tue May 24, 2011 5:12 pm
Reply with quote

apandey wrote:
Hi,
Can anyone pls let me value what is value of SQLCODE "00000031}"
I know "}" is EBCDIC code, but i am not able to find its actual value?

Is it -310 ? (It's a guess)

Yes.
Back to top
View user's profile Send private message
apandey

New User


Joined: 31 Aug 2009
Posts: 73
Location: Mumbai

PostPosted: Tue May 24, 2011 5:18 pm
Reply with quote

Can anyone pls provide list of EBCDIC code and its actual value ?
Actually I searched in this forum, few EBCDIC codes and its value is given but I was not able to find value "}" , I tried to goole it and then tried to "QW" in mainframe but not found the answer. Finally I posted.
I may be right but as i said it was a guess. I m still not sure with my guess.
Back to top
View user's profile Send private message
don.leahy

Active Member


Joined: 06 Jul 2010
Posts: 765
Location: Whitby, ON, Canada

PostPosted: Tue May 24, 2011 5:30 pm
Reply with quote

What is the hex value of the "31}" SQLCODE? Once you look at this, the meaning will be obvious.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Tue May 24, 2011 5:32 pm
Reply with quote

trouble searching?

ibmmainframes.com/viewtopic.php?t=40254
Back to top
View user's profile Send private message
apandey

New User


Joined: 31 Aug 2009
Posts: 73
Location: Mumbai

PostPosted: Tue May 24, 2011 6:05 pm
Reply with quote

Thanks everyone for quick response. icon_biggrin.gif
Back to top
View user's profile Send private message
apandey

New User


Joined: 31 Aug 2009
Posts: 73
Location: Mumbai

PostPosted: Mon May 30, 2011 3:06 pm
Reply with quote

Hi All,

1 more issue i am getting, I have a DB2 Insert statement, in which I was getting SQLcode -310.
Its description is (DECIMAL HOST VARIABLE OR PARAMETER number CONTAINS NON-DECIMAL DATA).
So I tried to find out all numeric fields which I am inserting in the table.
I found those numeric field and commented out in INSERT statement.
But still I am getting same Sqlcode -310. There are around 40 fields which i m inerting in my table to INSERT statement.

Is there any way to find out, on which exact field it is giving SQLCODE -310 ?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Mon May 30, 2011 3:24 pm
Reply with quote

a professional would use a CALL to DSNTIAR to expand the SQLCA after receiving a negative SQLCODE.

in the expansion of the -310 SQLCODE, it provids the parameter number of the parm causing the error.
Back to top
View user's profile Send private message
apandey

New User


Joined: 31 Aug 2009
Posts: 73
Location: Mumbai

PostPosted: Mon May 30, 2011 3:55 pm
Reply with quote

Hi dbzTHEdinosauer,

Sorry I have seen this in compile listing of program.
but i don't know how to expand CALL to DSNTIAR
or where to see the fields in CALL to DSNTIAR.

Can you pls help.
Thanks.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Mon May 30, 2011 4:05 pm
Reply with quote

Handling SQL error return codes in COBOL

Displaying SQLCA fields by calling DSNTIAR
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts SQLCODE = -122 while using the scalar... DB2 4
No new posts SQLCODE = -16002 when using XMLEXISTS DB2 1
No new posts Is SQLCODE -811 possible while fetchi... DB2 1
No new posts SQLCODE=-204 SQLSTATE=42704 DB2 4
No new posts Getting sqlcode 805 while executing R... DB2 10
Search our Forums:

Back to Top