RE: SQL State, SQL Code, Message Table?

RE: SQL State, SQL Code, Message Table?

 

  

No table, but a there is a message tie in for the command line. You access
it using the '?'.

Just type the SQLSTATE after the '?'

Ex: db2 "? 58004

For SQLCODE prefix with SQL

ex: db2 "? SQL0901".


SQL0901N The SQL statement failed because of a non-severe system
error. Subsequent SQL statements can be processed.
(Reason "<reason>".)

Explanation:

An error has occurred which is due to a system error. Processing
of the SQL statement has ended for reason "<reason>" (this is in
English only and is useful only to IBM support personnel).

User Response:

Record the message number (SQLCODE) and reason "<reason>".

If trace was active, invoke the Independent Trace Facility at
the operating system command prompt. Then contact your technical
service representative with the following information:

o Problem description

o SQLCODE

o reason "<reason>"

o SQLCA contents if possible

o Trace file if possible.



Federated system users: isolate the problem to the data source
failing the request (refer to the problem determination guide to
determine which data source is failing to process the SQL
statement) and take the necessary diagnostic steps for that data
source. The problem determination procedures for data sources
vary, so refer to the applicable data source manuals.

sqlcode : -901

sqlstate : 58004



David Baker
UDB World Site Admin
www.udbworld.com
[Email address protected]


-----Original Message-----
From: MHarris
[mailto:db2udbdba-ezmlmshield-x89208739.[Email address protected]
Sent: Friday, July 28, 2006 11:05 AM
To: LazyDBA Discussion
Subject: SQL State, SQL Code, Message Table?

We have DB2 on an iSeries. Is there a table in the iSeries database which
contains SQLState, SQLCode and meanings, as listed in the SQL Messages and
Code manual?

Max Harris
Technical Lead
Glazer's Family of Companies
[Email address protected]
(972)392-8054 Office
(214) 402-2455 Cell


---------------------------------------------------------------------
PLEASE CLICK REPLY-ALL TO SEND A REPLY TO EVERYONE
website: http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html



DB2 & UDB email list listserv db2-l LazyDBA home page