添加链接
link之家
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
  • DB2 does not allow the query to generate result set, or the query contains host variables, parameter markers, special registers, created temporary tables, declared temporary tables, session variables, IDENTITY_VAL_LOCAL function, NEXT VALUE expression, and/or PREVIOUS VALUE expression. Therefore the query cannot be put on hold or run in the background, as the state might not be valid at the time the query is actually executed.
  • The query would update a DB2 table, therefore it cannot be put on hold or run in background, as the state might no longer be valid at the time the query is actually executed.
  • The query cannot be queued because it contains nested routines.
  • The query cannot be put on hold or run in the background because it contains nested routines.
  • DB2 does not allow this query to be queued. This may occur when the query contains array inserts.
  • DB2 does not allow a query to be queued when the concentrator is turned on.
  • DB2 does not allow a query to be queued when the REOPT ALWAYS option is enabled for the query.
  • User response

    Contact the database administrator to examine the reason code and increase the appropriate cost threshold accordingly.

    SQL29010N The query submission has been cancelled.

    Explanation

    The user has cancelled the query submission. No query was submitted.

    SQL29011I Query query-ID will be run in the background.

    Explanation

    The user has chosen to run the query in the background.

    SQL29013I Query query-ID has been held.

    Explanation

    The query has been put in held state by Query Patroller.

    User response

    Contact the database administrator to have the query released.

    SQL29014N The value specified for DB2 registry variable registry-variable is invalid.

    Explanation

    The value specified for registry-variable is invalid because of the following restrictions by registry-variable :
    DQP_NTIER
    The value must be one of OFF, RUN[:timeout], or CHECK[:timeout].
    DQP_LAST_RESULT_DEST
    The length must not exceed 32 characters.
    DQP_TRACEFILE
    The length must not exceed 256 characters.

    User response

    Correct the value of the DB2 registry variable registry-variable with the db2set command and resubmit the query.

    SQL29015N Error encountered during job cancellation. Reason code = reason-code .

    Explanation

    An error was encountered while trying to cancel a job. The reason code maps to an SQL or DB2 message.

    User response

    Examine the reason code, correct the error, and retry the action again.

    SQL29017N Query query-id has been cancelled.

    Explanation

    The user has cancelled the query.

    SQL29020N An internal error has occurred. Error = error .

    Explanation

    An error has occurred during internal processing.

    User response

    Contact IBM Support and provide the db2diag log file and the qpdiag.log file.

    SQL29021N User user-ID is suspended.

    Explanation

    The user user-ID is suspended from submitting a query to the database.

    User response

    Contact the database administrator to have the user's submitter profile reactivated.

    SQL30000N Execution failed because of a Distributed Protocol Error that will not affect the successful execution of subsequent commands or SQL statements: Reason Code reason-code(subcode) ( text ).

    Explanation

    A system error occurred that prevented successful processing of the current environment command or SQL statement. This message (SQLCODE) is produced at statement compilation or execution time.

    The command or statement cannot be processed. The current transaction is not rolled back and the application remains connected to the remote database.

    User response

    Record the message number and the reason code. Record all error information from the SQLCA, if possible. Attempt to rerun the application.

    If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

    Required information:
  • Problem description
  • SQLCODE and reason code
  • SQLCA contents if possible
  • Trace file if possible.
  • SQL30002N The SQL statement cannot be executed due to a prior condition in a chain of statements.

    Explanation

    An SQL statement was chained to PREPARE, but the PREPARE statement has received a warning SQLCODE that requires the program or end user to either re-issue the chained statement or issue a different SQL request. This error can occur only in a client/server environment.
  • A distributed client using DRDA has chained an OPEN statement to a PREPARE, but the PREPARE statement received SQLCODE +1140.
  • The statement cannot be executed as chained.

    User response

    The statement must be sent again as a separate request.

    sqlcode : -30002

    sqlstate : 57057

    SQL30005N Execution failed because function not supported by the server: location location product ID pppvvrrm reason code reason-code(subcode) .

    Explanation

    The current SQL statement failed because the SQL statement was routed to a server that does not support the requested function. The error was such that it will not preclude the successful execution of further SQL statements.

    The statement cannot be executed. The SQLCA is formatted.

    User response

    Notify the DBA for assistance in analyzing the SQL statement that prompted this SQL code.

    location identifies the name of the server that could not support the required database protocols to perform the requested function. The product identifier is in the form <pppvvrrm>. It is an eight-byte field with alphanumeric characters, and identifies the product that could not support the function. ppp identifies the specific database product. vv identifies the product version. rr identifies the product release. m identifies the product modification level.

    Possible values for ppvvrrm :
    DSN for zOS, ARI for VM/VSE, SQL for Linux/Unix/Windows, QSQ for iSeries, and JCC for Java.
    Version number
    Release level
    Modification level
    To correct the problem, identify the function that is not supported. To determine what function was not supported and why, refer to the reason-code that was specified. Here are the possible values for the reason-code , and the functions they correspond to:
    LONG_STMTS
    LONG255_IDS
    EXTENDED_DESCRIBE
    EXTENDED_DIAGNOSTICS
    KEEP_DYNAMIC
    MULTI_ROW_FETCH
    MULTI_ROW_INSERT
    SQL_CANCEL
    SCROLLABLE_CURSORS
    CURSOR_ATTRIBUTES
    MONITORING
    SELECT_WITH_INSERT
    DATA_ENCRYPTION
    PACKAGE_PATH
    2PC_INCOMPATIBILITY
    Lastly, you may use the subcode value to further identify the problem. When non-zero, the subcode consists of a one-byte code to indicate how the error was detected in the network:
  • If '01'x, then the local DB2 that is acting as the requestor detected the error. The location and PRDID identify the server in error.
  • If '02'x, then the server detected the error. The location and PRDID identify the location and level of the local database server.
  • If '03'x, then an intermediate server (hop site) detected the error and the error and the location and PRDID identify the server in error.
  • If '04'x, then an intermediate server (hop site) detected the error and the error and the location and PRDID identify the server in error.
  • If '05'x, then an intermediate server (hop site) detected the error. SYNCLOG mapping error. Unable to map the end server's IPv6 address to a IPv4 address.
  • sqlcode : -30005

    sqlstate : 56072

    SQL30020N Execution of the command or SQL statement failed because of a syntax error in the communication data stream that will affect the successful execution of subsequent commands and SQL statements: Reason Code reason-code(subcode) .

    Explanation

    The command or statement cannot be processed. The current transaction is rolled back and the application is disconnected from the remote database.

    Some possible reason codes include:

    Indicates that the user is not authorized to perform the requested command.

    The DRDA data stream for the request contains a syntax error.

    The command could not be completed because of a permanent error. In most cases, the server will be in the process of an abend.

    A command sent from the client has resulted in an unarchitected and implementation specific condition on the remote server for which there is no architected message to return to the client.

    If the remote server is DB2 UDB for OS/390,zOS then check the console log for information about this error.

    If the remote server is DB2 UDB for iSeries, the job log of the server job, and/or a first failure data capture (FFDC) spooled file is usually necessary to determine the cause of the error.

    If the remote server is DB2 Database for Linux, UNIX, and Windows, then check the remote database server's administration notification log for information regarding this error.

    The target server has received an invalid data description. If a user SQLDA is specified, ensure that the fields are initialized correctly. Also, ensure that the length does not exceed the maximum allowed length for the data type being used.

    If you are using the DB2 Connect product in a gateway server environment with downlevel clients, this error may occur if your application's host variables and the queried table's column descriptions do not match.

    User response

    • For reason code 121C, contact your DBA to see if you are authorized to perform requested command.
    • For reason code 220A, if programming the SQLDA directly, ensure that fields are initialized correctly and the length does not exceed the maximum allowed length for the data type being used. If you are using DB2 Connect as described in Explanation, check that application host variables and table's column descriptions match.
    • For reason code 124C, one common case involves executing a stored procedure. If this case applies, ensure that you have correctly defined the stored procedure parameters, with type and length matching the types of the corresponding table columns.
    • If you are unable to resolve the problem (or if you have received reason codes not explained in this message), refer your DBA to the following instructions:

    • Search http://www.ibm.com/software/data/support/ for APARs which might cover the situation you are experiencing.
    • Attempt to connect the remote database and rerun the application. Record the following information and contact IBM support:
    • For DB2 for z/OS Data Server, invoke the Independent Trace Facility and retry the scenario to collect the trace information. Provide the z/OS trace, the z/OS console log, the db2support output from the DB2 Connect server, and the db2support output from the IBM Data Server Client located with the application (if not coresident with the DB2 Connect Server).
    • For DB2 for iSeries Data Server, collect any FFDC data generated by the failing DRDA server job, the db2support output from the DB2 Connect Server, and the db2support output from the IBM Data Server Client located with the application (if not coresident with the DB2 Connect Server).
    • Problem description
    • SQLCODE and reason code
    • SQLCA contents, if possible
    • IBM Data Server Client and DB2 Connect Server trace file if possible.
    • SQL30021N Execution failed because of a Distributed Protocol Error that will affect the successful execution of subsequent commands and SQL statements: Manager manager at Level level not supported.

      Explanation

      A system error occurred that prevented successful connection of the application to the remote database. This message (SQLCODE) is produced for SQL CONNECT statement. manager and level are numeric values that identify the incompatibility between the client and the server.

      The command cannot be processed.

      User response

      Record the message number, the manager , and level values. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database again.

      If the problem persists, invoke the Independent Trace Facility at the operating system command prompt. Then, contact your service representative with the following information:
    • Problem description
    • SQLCODE and reason code
    • SQLCA contents if possible
    • Trace file if possible.
    • SQL30040N Execution failed because of unavailable resources that will not affect the successful execution of subsequent commands and SQL statements: Reason reason , Type of Resource resource-type , Resource Name resource-name , Product ID product-ID .

      Explanation

      The application cannot process the command or SQL statement because the specified resource has run out. The current transaction is not rolled back and the application remains connected to the remote database.

      The command cannot be processed.

      User response

      Increase the size of the specified resource and resubmit the command.

      sqlcode : -30040

      sqlstate : 57012

      SQL30041N Execution failed because of unavailable resources that will affect the successful execution of subsequent commands and SQL statements: Reason reason , Type of Resource resource-type , Resource Name resource-name , Product ID product-ID .

      Explanation

      The application cannot process the command or SQL statement because resources are not available at the remote database. This SQLCODE is produced at statement compilation or processing time.

      Federated system users: this situation can also be detected by the data source.

      If the resource-name is "Encrypt" or "Decrypt", the user exits for password encryption or decryption are unavailable or had an error.

      The command or statement cannot be processed.

      User response

      Investigate the remote database system environment.

      Federated system users:

    • If the password encryption or decryption user exit failed, reason is the integer value that the federated server received when invoking the user exit. Ensure that no errors occurred when the encryption and decryption user exits were link-edited with the federated server.

      If using a user-supplied user exit, check the user exit source code to determine why the reason was returned. If the error is found in the user exit source code, fix the error, link-edit the object code with the federated server, and reissue the failing command or statement.

    • For all other cases, isolate the problem to the data source failing the request, correct the problem at the data source, and reissue the failing command or statement.
    • sqlcode : -30041

      sqlstate : 57013

      SQL30050N number command or SQL statement invalid while bind is in progress.

      Explanation

      An application attempted to issue a command or SQL statement that is not valid while a precompile/bind operation is in progress. <number> is a numeric value that identifies the erroneous command or SQL statement.

      The command or statement is not processed.

      User response

      If the application is not the database manager precompiler/binder, verify that bind is not active before issuing the command or SQL statement.

      If the application is the database manager precompiler/binder, record the message number (SQLCODE) and the <number> value. Record all error information from the SQLCA, if possible. Attempt to perform the bind operation again.

      If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and reason code
    • SQLCA contents if possible
    • Trace file if possible.
    • Explanation

      An attempt has been made to issue a precompile/bind operation when precompile/bind is not active or an attempt was made to use an invalid package name and/or consistency token during an active precompile/bind operation.

      The command or statement cannot be processed.

      User response

      If the application is not the database manager precompiler/binder, verify that precompile/bind is active before issuing the bind operation and that correct information is being passed on the bind operation.

      If the application is the database manager precompiler/binder, record the message number (SQLCODE) and all error information from the SQLCA, if possible. Attempt to perform the operation again.

      If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and reason code
    • SQLCA contents if possible
    • Trace file if possible.
    • Explanation

      The SQL statement being compiled is not recognized by the precompiler and cannot be processed by the database.

      The statement cannot be processed.

      User response

      Ensure that the statement is correct and attempt to perform the operation again. If the problem continues, remove the statement from the program.

      sqlcode : -30052

      sqlstate : 42932

      SQL30053N The value for OWNER failed the authorization check at the remote database.

      Explanation

      The value specified for the OWNER option on the precompile/bind failed the authorization check at the remote database. This SQLCODE is produced during precompile/bind. It is not produced by the database manager precompiler/binder.

      The precompile/bind operation cannot be processed.

      User response

      Ensure that you are authorized to use the ID specified for the OWNER option, or do not use the OWNER option.

      sqlcode : -30053

      sqlstate : 42506

      SQL30060N authorization-ID does not have the privilege to perform operation operation .

      Explanation

      Authorization ID <authorization-ID> attempted to perform the specified <operation> without having been granted the proper authorization to do so. This SQLCODE is produced at statement compilation or processing time.

      The statement cannot be processed.

      User response

      Ensure that the <authorization-ID> has been granted the authorization necessary to perform the desired operation.

      sqlcode : -30060

      sqlstate : 08004

      SQL30061N The database alias or database name name was not found at the remote node.

      Explanation

      The database name is not an existing database at the remote database node.

      The statement cannot be processed.

      User response

      Resubmit the command with the correct database name or alias.

      Federated system users: check to ensure that the entry in SYSCAT.SERVERS correctly specifies the database name of the data source.

      sqlcode : -30061

      sqlstate : 08004

      SQL30070N command-identifier Command is not supported.

      Explanation

      The remote database received a command that it does not recognize. The current environment command or SQL statement cannot be processed successfully, nor can any subsequent commands or SQL statements.

      The current transaction is rolled back and the application is disconnected from the remote database. The statement cannot be processed.

      User response

      Record the message number (SQLCODE) and the command identifier. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database and rerun the application.

      If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and command identifier
    • SQLCA contents if possible
    • Trace file if possible.
    • Explanation

      The remote database received data it does not recognize. The current environment command or SQL statement cannot be processed successfully, nor can any subsequent commands or SQL statements.

      The current transaction is rolled back and the application is disconnected from the remote database. The command cannot be processed.

      User response

      Record the message number (SQLCODE) and the object identifier. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database and rerun the application.

      If sufficient memory resources exist and the problem continues,

      If trace was active, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and object identifier
    • SQLCA contents if possible
    • Trace file if possible.
    • Explanation

      The remote database received data it does not recognize. The current environment command or SQL statement cannot be processed successfully, nor can any subsequent commands or SQL statements.

      The command cannot be processed.. The current transaction is rolled back and the application is disconnected from the remote database.

      User response

      Record the message number (SQLCODE) and the parameter identifier. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database and rerun the application.

      If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and parameter identifier
    • SQLCA contents if possible
    • Trace file if possible.
    • Explanation

      The remote database received data it does not recognize. The current environment command or SQL statement cannot be processed successfully, nor can any subsequent commands or SQL statements.

      The current transaction is rolled back and the application is disconnected from the remote database. The command cannot be processed.

      User response

      Record the message number (SQLCODE) and the parameter identifier. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database and rerun the application.

      If sufficient memory resources exist and the problem continues,

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

      Required information:
    • Problem description
    • SQLCODE, parameter identifier, and value
    • SQLCA contents if possible
    • Trace file if possible.
    • Some possible parameter identifiers include:
      The target server does not support the data type requested by the application requester. For example, when DB2 Connect is used to connect to DB2 2.3, this error will be returned unless the proper PTF is applied to DB2 2.3. Ensure that the level of the server is supported by the requester.
      119C, 119D, 119E
      The target server does not support the CCSID requested by the application requester. Ensure the CCSID used by the requester is supported by the server.
    • 119C - Verify the single-byte CCSID.
    • 119D - Verify the double-byte CCSID.
    • 119E - Verify the mixed-byte CCSID.
    • Explanation

      The client received a reply it does not recognize. The current environment command or SQL statement cannot be processed successfully, nor can any subsequent commands or SQL statements.

      The current transaction is rolled back and the application is disconnected from the remote database. The statement cannot be processed.

      User response

      Record the message number (SQLCODE) and the reply identifier. Record all error information from the SQLCA, if possible. Attempt to connect to the remote database and rerun the application.

      If sufficient memory resources exist and the problem continues, invoke the Independent Trace Facility at the operating system command prompt.

      Contact your technical service representative with the following information:

      Required information:
    • Problem description
    • SQLCODE and reply identifier
    • SQLCA contents if possible
    • Trace file if possible.
    • SQL30080N A communication error reason-code occurred sending or receiving data from the remote database.

      Explanation

      The reason-code contains the original error codes reported by Communications Manager.

      For APPC error codes, the format is pppp-ssssssss-dddddddd where pppp is the primary return code, ssssssss is the secondary return code and dddddddd is the sense data. Each of these error code values is represented in hexadecimal notation. Possible primary and secondary error codes include 0003-00000004 and 0003-00000005, which indicate that a conversation with the Database Server could not be allocated. Sense data will only be displayed for an APPC ALLOCATE error.

      The command cannot be processed. The connection attempted to the database is unsuccessful or the current transaction to the connected database is rolled back and the application is disconnected from the remote database.

      Refer to the document IBM Communications Manager 1.0 APPC Programming Guide and Reference (SC31-6160) for explanation of the APPC primary and secondary return codes. For details of APPC sense data, refer to the IBM Communications Manager 1.0 Problem Determination Guide (SC31-6156) .

      User response

      Ensure that both the database manager and Communications Manager are started at the Database Server and that all Communications Manager configuration parameters are correct.

      Note: If the reason code embedded in your message is 0003-084C0001 one possible cause for this message is that you are trying to make a remote connection to a workstation that is not a server. Verify that the remote workstation is a server. If it is not a server, install the database manager as a server.
      sqlcode : -30080

      sqlstate : 08001

      SQL30081N A communication error has been detected. Communication protocol being used: protocol . Communication API being used: interface . Location where the error was detected: location . Communication function detecting the error: function . Protocol specific error code(s): rc1 , rc2 , rc3 .

      Explanation

      An error has been detected by the communication subsystem.

      The following is a description of the token values:

      protocol , location

      Communication protocol used and information that uniquely identifies the node that detected the error. If the location information is not available at the time that the error occurred, then the location token is not filled in. Valid token values are:

    • protocol TCP/IP; location is the IPv4 or IPv6 address.
    • protocol APPC; location is the fully qualified LU name (networkID.LUname).
    • protocol MQ; location is the MQ queue name.
    • protocol SOAP, SSL, SOCKS, HTTP; location is the Internet address in dot notation.
    • Reason codes rc1 , rc2 , rc3 represent:
    • If present, rc1 contains the errno returned by the TCP/IP function. On Windows, this is a WSA errno.
    • If present, rc2 contains the h_errno value returned by a TCP/IP name resolution function. On Windows, this is a WSA error number.
    • If rc3 is present and contains "0", the remote side has terminated the connection. If the error was received on the client, then the remote side could be a server or gateway. If the error was received on the gateway, the remote side could be the client or server.
    • If protocol = TCP/IP, rc1 =*, rc2 =*, and rc3 =0, possible causes include:
    • The database agent at the server was forced off by the system administrator.
    • A database agent could not be started at the server because a memory limitation was reached on the system.
    • The connection might have been closed by the remote server at the TCP/IP level.
    • The database agent at the server was terminated due to an abnormal termination of a key database manager process.
    • On Windows, if protocol = TCP/IP, function = WSAStartup, and rc1 = 0, then rc2 contains the Windows Sockets Specification version level requested by DB2, and rc3 contains the Windows Sockets Specification version level supported by the Windows Sockets DLL. Cause: There was a version level mismatch.
    • If protocol = TCP/IP, function = connect, rc1 = ECONNREFUSED/WSAECONNREFUSED, AIX (79), Windows (10061), linux (111), SUN (146), HP (239), the attempt to connect was rejected. Possible causes:
    • The remote database server has not been cataloged correctly at the client. In a client-gateway-server scenario, ensure the host entries are cataloged correctly on the gateway.
    • The database manager configuration file at the server has not been configured properly with the proper communication parameters. Check that the SVCENAME database manager configuration parameter has been configured properly with the TCP/IP service name or port number and that the port number is unique. If database manager configuration parameters have been updated at the server, the database manager must be stopped and re-started for the changes to take effect. There might be a mismatch between the TCP/IP service name or port number specified on the server and on the client. Ensure the service name maps to the correct port number by checking the services file. You can check this by reading the services file or checking the output from running the command "netstat -a".
    • A firewall at the remote database server has prevented the connection from being established. Verify that the firewall is properly configured to accept connection requests from the client.
    • The DB2COMM environment variable at the server does not specify the communication protocol used by the client. Check that TCPIP has been specified. Issue db2set to see what has already been set. Run the command "db2set DB2COMM=TCPIP" to set the value.
    • The database manager at the server has not been started, or has not been started successfully, or has gone down. The server should have returned SQL1063N, and not SQL5043N. If you set the database manager configuration parameter DIAGLEVEL to 4 using the command "db2 update dbm cfg using diaglevel 4" prior to issuing the "db2start" command, then the administration notification log will provide detailed information on which protocols were started successfully. Check the administration notification log.
    • The server might be too busy to handle the volume of incoming connections at this time.
    • Network failure, contact your network administrator. You can try a test using the protocol tester, pctt, to verify this is not a DB2 problem.
    • If protocol = TCP/IP, function = connect, rc1 = ETIMEDOUT/WSAETIMEDOUT, AIX (78), Windows (10060), linux (110), SUN (145), HP (238), attempt to connect timed out before a connection was made. Possible causes:
    • An incorrect host name or IP address was cataloged in the hostname field of the node directory on the client and/or gateway.
    • The network is slow, or the server might be too busy to respond to the connect request within a reasonable amount of time, you might need to adjust your system TCP connect timeout value and/or the DB2TCP_CLIENT_CONTIMEOUT value.
    • If protocol = TCP/IP, function = recv, rc1 = ECONNRESET/WSAECONNRESET, AIX (73), Windows (10054), linux (104), SUN (131), HP (232), the connection was reset by the remote side executing a "hard" or "abortive" close. Possible causes:
    • The connection might have been closed by the remote gateway or server at the TCP/IP level (eg. firewall problem, power failure, network failure).
    • Client side connection pooling is enabled and is not handling connection failures. Code the application to retry a connection if a failure is received when connecting to the database and connection pooling is enabled.
    • Might have been caused by a thread timeout on the host machine. Check the system log on the host for the presence of the IDTHTOIN message. Adjust the setting if applicable. If this cannot be adjusted, either disable connection pooling on the gateway, or ensure all objects are properly closed (eg. cursors with hold when the application completes its operation).
    • The database agent at the server was forced off by the database administrator.
    • The database agent at the server was terminated due to an abnormal termination of a key database manager process.
    • If protocol = TCP/IP, function = recv, rc1 = ETIMEDOUT/WSAETIMEDOUT, AIX (78), Windows (10060), linux (110), SUN (145), HP (238), the connection was dropped because the remote system failed to respond. Possible causes:
    • SQLCancel() was called from a CLI application because the application set the Query Timeout value or there was an explicit cancel request. Adjust the Query Timeout value set by the application. If this is not possible, adjust the QueryTimeoutInterval setting in the db2cli.ini file. Use QueryTimeoutInterval=0 (no timeout) in the db2cli.ini file to test whether QueryTimeout is the cause of your application's failure. The failure of an existing connection is expected in this scenario.
    • The network is slow, or the server might be too busy to respond to the recv request within a reasonable amount of time, you might need to adjust your system TCP recv timeout value.
    • If protocol = TCP/IP, function = selectForConnectTimeout, rc1 = EINPROGRESS/0, AIX (55), Windows (0), linux (115), SUN (150), HP (245), the connect request timed out before it could complete successfully. Possible causes:
    • Either the system connect timeout or the timeout value set by DB2TCP_CLIENT_CONTIMEOUT caused the timeout. Try adjusting these values.
    • If protocol = TCP/IP, function = selectForRecvTimeout, rc1 is irrelevant, the recv request timed out before it could complete successfully. Possible causes:
    • Either the system recv timeout or the timeout value set by DB2TCP_CLIENT_RCVTIMEOUT caused the timeout. Try adjusting these values.
    • rc1 contains the return code from the CPI-C function.
    • If present, rc2 contains the global errno value from the CPI-C function call.
    • rc3 is not applicable.
    • If protocol is MQ

    • rc1 contains the function completion code, 1 for a warning and 2 for an error.
    • rc2 contains the MQ-specific error code.
    • rc3 is not used for MQ.
    • If protocol is SOAP, rc1 contains the return code from the SOAP communication function.

      If protocol is SSL, rc1 contains the return code from the Secure Sockets Layer (GSKit).

      If protocol is SOCKS

    • rc1 contains the return code from the SOCKS proxy server.
    • rc2 contains the version (4 or 5) of the protocol.
    • rc3 contains the authentication method used (SOCKS v5.)
    • If protocol is HTTP, rc1 contains the HTTP return code from the remote HTTP server.

      User response

      Correct the problem indicated by the combination of reason code and token values returned.

      sqlcode : -30081

      sqlstate : 08001, 5UA0G, 5UA0H

      SQL30082N Security processing failed with reason reason-code ( reason-string ).

      Explanation

      An error occurred during security processing. The cause of the security error is described by the reason-code and corresponding reason-string value.

      The following is a list of reason codes and corresponding reason strings:

      0 (NOT SPECIFIED)

      The specific security error is not specified.

      1 (PASSWORD EXPIRED)

      The password specified in the request has expired.

      2 (PASSWORD INVALID)

      The password specified in the request is not valid.

      3 (PASSWORD MISSING)

      The request did not include a password.

      4 (PROTOCOL VIOLATION)

      The request violated security protocols.

      5 (USERID MISSING)

      The request did not include a userid.

      6 (USERID INVALID)

      The userid specified in the request is not valid.

      7 (USERID REVOKED)

      The userid specified in the request has been revoked.

      8 (GROUP INVALID)

      The group specified in the request is not valid.

      9 (USERID REVOKED IN GROUP)

      The userid specified in the request has been revoked in the group.

      10 (USERID NOT IN GROUP)

      The userid specified in the request is not in the group.

      11 (USERID NOT AUTHORIZED AT REMOTE LU)

      The userid specified in the request is not authorized at the remote Logical Unit.

      12 (USERID NOT AUTHORIZED FROM LOCAL LU)

      The userid specified in the request is not authorized at the remote Logical Unit when coming from the local Logical Unit.

      13 (USERID NOT AUTHORIZED TO TP)

      The userid specified in the request is not authorized to access the Transaction Program.

      14 (INSTALLATION EXIT FAILED)

      The installation exit failed.

      15 (PROCESSING FAILURE)

      Security processing at the server failed.

      16 (NEW PASSWORD INVALID)

      the password specified on a change password request did not meet the server's requirements.

      17 (UNSUPPORTED FUNCTION)

      the security mechanism specified by the client is invalid for this server. Some typical examples:

    • The client sent a new password value to a server that does not support the change password function.
    • The client sent SERVER_ENCRYPT authentication information to a server that does not support password encryption. Authentication type catalog information must be the same at the server and the client.
    • The client sent a userid (but no password) to a server that does not support authentication by userid only.
    • The client has not specified an authentication type, and the server has not responded with a supported type. This might include the server returning multiple types from which the client is unable to choose.
    • The CLIENT AUTHENTICATION type is not supported by "IBM Data Server Driver for ODBC and CLI" and "IBM Data Server Driver package"
    • 24 (USERNAME AND/OR PASSWORD INVALID)

      The username specified, password specified, or both, are invalid. Some specific causes are:

    • If you have recently changed permissions on DB2 critical files such as db2ckpw or moved to a new Fixpak, the db2iupdt command which updates the instance might not have been run.
    • The username being used might be in an invalid format. For example, on UNIX and Linux platforms, usernames must be all be lowercase.
    • An error might have been made in specifying the catalog information. For example, the correct authentication type might not have been specified or, if applicable, the remote server might not have been cataloged on the local system.
    • 26 (UNEXPECTED SERVER ERROR)

      The server security plugin encountered an unexpected error. The administration notification log file on the server contains more specific problem information. The following are examples of issues that can cause problems:

    • The security service was not started.
    • The userid starting the DB2 service did not have admin privileges.
    • 57 (ACCESS TOKEN ALGORITHM NOT CONFIGURED)
      The token used to connect contains an algorithm which is supported but not configured in the token configuration file.
    • Run DB2IUPDT <InstName> to update the instance.
    • Ensure that the username created is valid. Review the DB2 General Naming Rules.
    • Ensure that catalog information is correct.
    • Fix the problem identified by the plugin error message text in the administration notification log.

      If you are unable to correct the problem, invoke the Independent Trace Facility and retry the scenario to collect information for IBM support.

      Verify that the server credential is provided during security plugin initialization and that it is in a format recognized by the security plugin. As the credential will be used to accept contexts, it must be an ACCEPT or BOTH credential.

      Contact your DBA. The server's credential must be renewed before the command is resubmitted. If renewing alters the credential handle, then a db2stop and db2start will be necessary. For information on how to renew your server's credential, consult the documentation available for the authentication mechanism used by the security plugin.

      Resubmit the statement. If the problem still exists, then verify that the client security plugin is generating a valid security token.

      Check the administration notification log file for the name of the required missing API. Add the missing API to the security plugin.

      Specify the right type of security plugin in the appropriate database manager configuration parameter. For example, do not specify a userid-password based security plugin for the SRVCON_GSSPLUGIN_LIST database manager configuration parameter.

      Install the matching security plugin that the database server used on the client. Ensure that the indicated security plugin is located in the client-plugin directory.

      Check the administration notification log file on the client for more information. Fix the problem identified by the error message text in the administration notification log.

      Specify a valid security plugin name. The name should not contain any directory path information.

      Ensure that the security plugin is using a supported version of the APIs and that it is reporting a correct version number.

      Check the administration notification log file on the client for more information. Fix the problem identified by the error message text in the administration notification log.

      Check the administration notification log file for the principal name. Make sure the principal name is in a format that is recognized by the security plugin.

      Verify that the client credential (generated by db2secGenerateInitialCred or provided as an inbound delegated credential) is in a format recognized by the security plugin. As the credential will be used to initiate contexts, it must be an INITIATE or BOTH credential.

      The user issuing the statement must obtain the appropriate credentials (or re-obtain their initial credentials) and then resubmit the statement.

      Resubmit the statement. If the problem still exists, then verify that the server security plugin is generating a valid security token.

      Re-establish a trusted connection with valid credentials and re-submit a switch user request.

      To enable local client or server authentication for non-root installations, the system administrator must run the db2rfe script. Alternatively, authentication can be done using a security plugin.

      If additional explanation is required, contact your administrator for the query manager product.

      sqlcode : -30082

      sqlstate : 08001

      SQL30083N Attempt to change password for user id uid failed with security reason reason-code ( reason-string ).

      Explanation

      The attempt to change password was rejected due to invalid or incorrect security information. The cause of the security error is described by the reason-code and corresponding reason-string values.

      The following is a list of reason codes and corresponding reason strings:
      0 (NOT SPECIFIED)
      The specific security error is not specified.
      1 (CURRENT PASSWORD INVALID)
      The old password specified in the request is not valid.
      2 (NEW PASSWORD INVALID)
      The password specified in the request is not valid under the password rules imposed by the system where password was to be changed.
      3 (CURRENT PASSWORD MISSING)
      The request did not include an old password.
      4 (NEW PASSWORD MISSING)
      The request did not include a new password.
      5 (USERID MISSING)
      The request did not include a userid.
      6 (USERID INVALID)
      The userid specified in the request is not valid.
      7 (USERID REVOKED)
      The userid specified in the request has been revoked. Passwords can not be changed for revoked userids.
      14 (INSTALLATION EXIT FAILED)
      The installation security exit failed.
      15 (PROCESSING FAILURE)
      Security processing at the server failed.
      17 (UNSUPPORTED FUNCTION)
      Change password function is not supported by the system, or change password function is not supported at this time because of the user account restrictions.
      19 (USERID DISABLED or RESTRICTED)
      The userid has been disabled, or the userid has been restricted from accessing the operating environment at this time.
      23 (CHGPWD_SDN in DCS entry is not configured)
      To change an MVS password on a host system connected via SNA, the DCS database must be cataloged with the ,,,,,,,CHGPWD_SDN parameter string. The ,,,,,,,CHGPWD_SDN parameter string identifies the symbolic destination name for Password Expiration Management (PEM).
      24 (USERNAME AND/OR PASSWORD INVALID)
      The username specified, password specified, or both, are invalid.

      User response

      Ensure that the proper userid, current and new passwords are supplied.

      The userid may be disabled, the userid may be restricted to accessing specific workstations, or the userid may be restricted to certain hours of operation.

      Instructions for some specific reason codes follow:
      Check the file db2pem.log in the instance subdirectory (typically "db2") for a detailed description of the problem encountered.
      Catalog the DCS database using the ,,,,,,,CHGPWD_SDN parameter, as specified in the DB2 Connect User's Guide .

      SQL30090N Operation invalid for application execution environment. Reason code = reason-code .

      Explanation

      The operation is invalid for the application execution environment. For example, an operation might be invalid for applications that have special restrictions on statements or APIs - applications such as those that operate in an XA Distributed Transaction Processing environment, such as CICS; those that operate with CONNECT type 2 connection settings; or those that use federated system functionality to update multiple heterogeneous data sources. The operation was rejected.

      Possible reason codes are:

      an SQL request that changes data (such as an INSERT or a CREATE) was issued against a read-only database; or, a stored procedure was invoked against a read-only database. Read-only databases include the following types:

    • Databases accessed using DRDA when operating in a unit of work which has connection setting SYNCPOINT TWOPHASE and executing in a non-XA/DTP environment when either a Synchpoint Manager is not being used or the remote DRDA database does not support level 2 DRDA protocol.
    • Databases accessed by DRDA in an XA/DTP environment when either a Synchpoint Manager gateway is unavailable or the remote DRDA database does not support level 2 DRDA protocol.
    • Databases which were not the first database updated when the SYNCPOINT ONEPHASE connection setting is in effect for the unit of work.
    • XA/DTP environment, or
    • federated server accessing a nickname defined on a two phase commit datasource
    • Cursor hold is not supported in these environments.

      An operation is not supported for pass-through.

      The insert/update/delete operation requires the existence of a timestamp column and a unique index due to the restriction on thedata source .

      For an update/delete operation accessing data sources:

    • Fujitsu RDB2 requires the existence of a unique index.
    • An illegal combination of updatable cursors, cursor hold, and isolation level of Repeatable Read exists. Invalid combinations are:

    • Isolation level Repeatable Read and a WITH HOLD cursor
    • A WITH HOLD cursor with FOR UPDATE
    • An update request (or, a DDL operation that results in the update of a system catalog table) has been issued that would result in multiple data sources being updated when one or more of the data sources in the unit of work only supports one-phase commit. Possible causes are:

    • An attempt was made to update a data source that only supports one-phase commit, but a different data source has already been updated in the same unit of work.
    • An attempt was made to update a data source that supports two-phase commit, but a different data source that only supports one-phase commit has already been updated in the same unit of work.
    • An attempt was made to update a local federated server table, but a data source that only supports one-phase commit has already been updated in the same unit of work.
    • An attempt was made to update a data source that only supports one-phase commit when the application is operating with a CONNECT type 2 connection setting.
    • A federated insert, update, or delete operation, or a call to federated procedure with an SQL data access indication of MODIFIES SQL DATA is invalid in a function, a data-change-table-reference, a dynamic compound statement, a trigger, and an application execution environment where a

    • SAVEPOINT is in effect
    • scrollable cursor is used
    • target view contains multiple tables or nicknames
    • For reason 07,

      ensure that only one database is accessed within a unit of work for which EXEC SQL COMMIT or EXEC SQL ROLLBACK will be issued in place of syncpoint requests to an external transaction manager. If multiple databases must be accessed within the unit of work, utilize the commitment control interface provided by the external transaction manager product.

      For reason 08,

      ensure that all databases being accessed within a unit of work are under the commitment control of the same type of request: external transaction processing monitor (such as CICS SYNCPOINT) or local COMMIT and ROLLBACK EXEC SQL.

      For reason 09,

      do one of the following steps:

    • Execute the transaction as an XA/DTP global transaction.
    • Access the database in a non-XA/DTP environment.
    • Do not use the services of the Synchpoint Manager for the database connection if the transaction is read-only.
    • Submit a COMMIT or ROLLBACK before issuing an update to a different data source.
    • If multiple data sources need to be updated within a unit of work, make sure the db2_two_phase_commit server option has been set to 'Y' for all the data sources that need to be updated.
    • If the data source to be updated supports only one-phase commit and the application is operating with a CONNECT type 2 connection setting, change the application to operate with a CONNECT type 1 connection setting.
    • For reason 22,

      Either remove the federated insert, update or delete operation, or the call to the federated procedure with an SQL data access indication of MODIFIES SQL DATA or:

    • execute the federated insert, update, or delete operation outside of the function, the data-chagne-table-reference, they dynamic compound statement or trigger
    • execute the call to the federated procedure with an SQL data access indication of MODIFIES SQL DATA outside of the function, the dynamic compound statement or trigger
    • release the savepoint that is in effect
    • remove the use of the scrollable cursor
    • redefine the target view to refer to only one table or nickname
    • execute the federated insert, update, or delete operation outside of the trigger.
    • For reason 24,

      If the failing statement was CREATE TYPE MAPPING, do not resubmit the statement. If the failing statement was CREATE SERVER, examine the federation catalog for type mappings for the server type and drop these mappings. In either case, consult the data source documentation for information about types and type mappings supported by the data source.

      For reason code 25,

      If the failing statement was CREATE FUNCTIONMAPPING, do not resubmit the statement. If the failing statement was CREATE SERVER, examine the federation catalog for function mappings for the server type and drop these mappings. In either case, consult the data source documentation for information about functions and function mappings supported by the data source.

      For reason code 26,

      Ensure that the trusted userid is not switched during a transaction.

      For reason code 27,

      An application cannot access multiple 2-phase commit servers of this data source in the same connection. Execute the application in a different environment.

      For reason code 28,

      An application cannot access 1-phase commit server while a connection to 2-phase commit server is active, or vice versa. Execute the application in a different environment.

      For reason code 31,

      Perform the following steps:

    • Manually add the path of the client library for the new wrapper to the DB2LIBPATH environment variable.
    • Restart the database manager.
    • Execute the CREATE WRAPPER statement again.
    • Explanation

      Bind options were specified on the REBIND request however the database server does not support respecification of any bind options. The bind options specified will be ignored and the options from the original BIND request will be used.

      User response

      No action is required. This is a warning situation only.

      If the database server returned an additional warning SQLCA, the "sqlerrmc" tokens will indicate the following information about this additional SQLCA in this order:
    • sqlcode (SQL return code)
    • sqlstate (universal SQL return code)
    • sqlerrp (product name)
    • sqlerrmc (SQL message tokens)
    • Explanation

      While processing the BIND or PRECOMPILE parameters, either the BIND or PRECOMPILE option or the value is not acceptable, or the option and value pair is not appropriate.

      The statement cannot be processed.

      User response

      Examine the command options and values to determine the error and resubmit the command.

      sqlcode : -30104

      sqlstate : 56095

      SQL30106N Invalid input data detected for a multiple row INSERT operation.

      Explanation

      An error was detected with the input data for one row of a multiple row INSERT operation. No further rows will be inserted. For an atomic operation, all inserted rows are rolled back. For a non-atomic operation, rows inserted successfully before the row containing the invalid input data was encountered are not rolled back.

      User response

      Correct the row containing the invalid input data and submit the multiple row INSERT again for the rows that did not get inserted.

      sqlcode : -30106

      sqlstate : 22527

      SQL30108N A connection failed in an automatic client reroute environment. The transaction was rolled back. Host name or IP address: host-name . Service name or port number: service-name . Reason code: reason-code . Connection failure code: connection-failure-code . Underlying error: underlying-error .

      Explanation

      You can enable database applications to continue to process transactions with minimal interruption from connection failures by using the automatic client reroute feature. This message is returned when automatic client reroute has detected a connection failure.

      reason-code

      The value of the token reason-code indicates which special registers would be applied to the new connection:

    • 1 or 3: All special register settings up to the point of failure would be returned.
    • 2 or 4: All special register settings (and for DB2 for z/OS Version 10.1.5 and later: session global variables) up to the previous commit point would be replayed on the new connection.
    • The value of the token reason-code also indicates whether connection would be re-established within the current group or in a new group:

    • 1 or 2: The connection would be re-established in the current group.
    • 3 or 4: The connection would be re-established in an alternate group.
    • host-name and service-name

      The value of the tokens host-name and service-name depend on the token reason-code :

    • When reason-code is 1 or 3, the value of the tokens host-name and service-name refer to the new connection.
    • When reason-code is 2 or 4, the value of the tokens host-name and service-name depend on whether or not workload balancing is enabled:
    • When workload balancing is enabled, the host name given in the token host-name and the IP address given in service-name refer to the connection that failed.
    • When workload balancing is not enabled, the host name given in the token host-name and the IP address given in service-name refer to the new connection.
    • Communication failure. For example: connection timeout or query timeout was configured, but before the time out occurred, a member failed over.
    • Database server action. For example: the DB2 member was shut down, or the database was quiesced.
    • An SQL error occurred.
    • Interrupt on client. For example: a query timed out or SQLCancel was called.
    • underlying-error

      The value of the token underlying-error depends on the value of the token connection-failure-code :

    • When connection-failure-code is 1 or 2, underlying-error contains the platform-specific error number. Example 1: when the SQLCODE that caused the connection to fail is -30081 and connection-failure-code is 1 or 2, underlying-error might contain the value of the runtime token rc1 of message SQL30081N. Example 2: for Java applications, this value is a communication exception message token that is received from the Java sockets API.
    • When connection-failure-code is 3, underlying-error contains the SQLCODE that caused the connection to fail.
    • When connection-failure-code is 4, underlying-error contains one of the following numerical values:
    • 1 - The client canceled the execution because a query timed out.
    • 2 - The driver received an interrupt request or a cancel request.
    • 3 - The client canceled the execution because the execution time exceeded the value of the queryTimeout property.
    • Recreate all session resources, including any session resource that might have been created in a previous transaction.
    • Re-issue all SQL statements.
    • sqlcode : -30108

      sqlstate : 08506

      SQL30109N A connection could not be re-established because the release level of any database server within the current group of servers or within an alternate group is not compatible with the release level of the original server. New host name or IP address: host-name . New server name or port number: service-name . Release level of the new connection: new-release-level . Release level of the original connection: old-release-level . Reason code: reason-code .

      Explanation

      There was an attempt to re-establish the connection on a different database server from within the current group of servers or on a database server in an alternate group. The reason code indicates which of these applies.

      A connection to the database server failed and a connection could not be re-established to an alternate server in the group as none of the available servers in the group had a release level compatible with the initial connection. The release level of the alternate server in the group to which the last connect attempt was made is not compatible with the release level of the original connection.

      A connection to the database server failed and a connection could not be re-established to a server in an alternate group of servers as none of the available servers in the alternate group had a release level compatible with the initial connection. The release level of the server in the alternate group to which the last connect attempt was made is not compatible with the release level of the original server in the original group.

      SQL32765W Warning or informational message information from an external product: token-list .

      Explanation

      A software product that interacts with the database manager, but is not part of the database product, is returning information about a warning or informational situation in token-list .

      User response

      Use the information in token-list along with any documentation available for the product that is returning the information to understand the situation being reported on.

      sqlcode : +32765

      sqlstate : (any SQLSTATE might be returned)

      SQL32766N Error message information from an external product: token-list .

      Explanation

      A software product that interacts with the database manager, but is not part of the database product, is returning information about an error situation in token-list .

      User response

      Use the information in token-list along with any documentation available for the product that is returning the information to determine how to handle this error situation.

      sqlcode : -32766

      sqlstate : (any SQLSTATE might be returned)