This is a discussion on Matching SQLCODES to SQL Statements within the DB2 forums, part of the Database Server Software category; --> Is there a guide, pamphlet, book, website, PDF or scroll somewhere which states the SQLCODES which are valid for ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Is there a guide, pamphlet, book, website, PDF or scroll somewhere which states the SQLCODES which are valid for each SQL statement (i.e., INSERT, CALL, FETCH, DECLARE CURSOR) in IBM DB2 (v7 or 8)? I sometimes fall into the situation where someone has coded (or not) a questionable EVALUATE SQLCODE statement after an EXEC SQL statement. Thanks to all of you, in advance, for your support! |
| |||
| On Nov 29, 2:55 pm, BugleBoy <dfaill...@gmail.com> wrote: > Is there a guide, pamphlet, book, website, PDF or scroll somewhere > which states the SQLCODES which are valid for each SQL statement > (i.e., INSERT, CALL, FETCH, DECLARE CURSOR) in IBM DB2 (v7 or 8)? > > I sometimes fall into the situation where someone has coded (or not) a > questionable EVALUATE SQLCODE statement after an EXEC SQL statement. > > Thanks to all of you, in advance, for your support! Hi, The SQLCODE seems to be included with each SQL Statement topic in the Info Center. For example, the V8 Insert statement has them in it: http://publib.boulder.ibm.com/infoce...n/r0000970.htm Is this what you are looking for? Louise McNicoll DB2 Information Development |
| |||
| > Hi, > > The SQLCODE seems to be included with each SQL Statement topic in the > Info Center. For example, the V8 Insert statement has them in it: > > http://publib.boulder.ibm.com/infoce...ic/com.ibm.db2... > > Is this what you are looking for? > > Louise McNicoll > DB2 Information Development Well ... it has some SQLSTATE codes for some specific conditions like ..."If the result table is empty, SQLCODE is set to +100 and SQLSTATE is set to '02000'." But, is there a table or display which lists the probable SQLCODEs for a specific statment, with out reading the whole explanation of the usage of the statement. Thanks for your help so far Louise! |
| |||
| On Dec 3, 5:33 pm, BugleBoy <dfaill...@gmail.com> wrote: > > Well ... it has some SQLSTATE codes for some specific conditions > like ..."If the result table is empty, SQLCODE is set to +100 and > SQLSTATE is set to '02000'." > > But, is there a table or display which lists the probable SQLCODEs for > a specific statment, with out reading the whole explanation of the > usage of the statement. > > Thanks for your help so far Louise Hi, I checked with our other writers and we don't have such a table or list. The best suggestion that I got for you was that you can perhaps use the search feature to return all the statements with a specific code or state. Regards, Louise McNicoll DB2 Information Development |
| ||||
| "BugleBoy" <dfaillace@gmail.com> wrote in message news:1aaf380d-fb3c-4ec6-9322-8936b1ffbba9@w34g2000hsg.googlegroups.com... > Is there a guide, pamphlet, book, website, PDF or scroll somewhere > which states the SQLCODES which are valid for each SQL statement > (i.e., INSERT, CALL, FETCH, DECLARE CURSOR) in IBM DB2 (v7 or 8)? > > I sometimes fall into the situation where someone has coded (or not) a > questionable EVALUATE SQLCODE statement after an EXEC SQL statement. > > Thanks to all of you, in advance, for your support! You can make an extract from "Message Reference Vol.2" db2m2e90.pdf and create a cross reference for sqlstates vs sqlcodes. /dg |