SQLDIAG |
Note:
This command is only available with Natural for
Db2.
The SQLDIAG
command provides diagnostic information about the
last SQL statement (other than a GET DIAGNOSTICS
statement) that was executed.
This diagnostic information is gathered as the previous SQL statement is executed. Some of
the information available through the GET DIAGNOSTICS
statement is also
available in the SQLCA.
For detailed information about the returned diagnostics information, see the IBM Db2
documentation of the GET DIAGOSTICS
statement.
Fields, which are prefixed with a plus sign (+), may contain more data than displayed on
the screen. You can display the full contents either when you position the cursor on the
field (description or data) and press Enter, or when you enter the abbreviation
of the field (which are the capital letters of the description) prefixed by the plus sign
(+) in the command line. For example, +SN
shows a window with the full value of
SERVER_NAME
.
The SQLDIAG
command can be issued either from the Natural NEXT
prompt or from within a Natural program (by using the FETCH
statement).
11:03:12 *** SQLDIAG Diagnostic Information *** 2006-04-15 - Statement Information - DB2_Last_Row ..................... 0 DB2_Number_Parameter_Markers ..... 0 DB2_Number_Result_Sets ........... 0 DB2_Return_Status ................ 0 DB2_SQL_Attr_Cursor_Hold ......... _Rowset .. _Scrollable ... _Type .. _Sensitivity .. DB2_Number_Rows .................. 0 Row_Count ........................ 0 More ............................. Number ........................... 1 Command ===> Enter-PF1---PF2---PF3---PF4---PF5---PF6---PF7---PF8---PF9---PF10--PF11--PF12--- Help Error Exit Updat Next Canc |
11:09:49 *** SQLDIAG Diagnostic Information *** 2006-04-15 - Condition Information 1 - +Server_Name ................. DAEFDB28 +CUrsor_Name ................. DB2_Error_Code1 ............. -500 DB2_Error_Code2 ... 0 _Code3 ............. 0 _Code4 ... -1 DB2_Internal_Error_Pointer .. -500 +DB2_Sqlerrd1(-6) .. -500 DB2_Module_Detecting_Error .. DSNXOTL +DB2_Ordinal_Token_1 ......... HGK.DEMO DB2_Row_Number .............. 0 DB2_Line_Number ............. 0 DB2_Returned_SQLCode ........ -204 DB2_Reason_Code ............. 0 Returned_SQLState ........... 42704 DB2_Message_ID .............. DSN00204E Message_Octet_Length ........ 0 +Message_Text ................ HGK.DEMO IS AN UNDEFINED NAME Command ===> Enter-PF1---PF2---PF3---PF4---PF5---PF6---PF7---PF8---PF9---PF10--PF11--PF12--- Help Error Exit Updat Prev Next Canc |
11:14:41 *** SQLDIAG Diagnostic Information *** 2006-04-15 - Connection Information - DB2_Authentication_Type .. DB2_Authentication_ID .... GGS DB2_Connection_State ..... 0 DB2_Connection_Status .... 0 DB2_Encryption_Type ...... DB2_Product_ID ........... DSN08010 DB2_Server_Class_Name .... QDB2 for DB2 UDB for z/OS Command ===> Enter-PF1---PF2---PF3---PF4---PF5---PF6---PF7---PF8---PF9---PF10--PF11--PF12--- Help Error Exit Updat Prev Canc |