Oracle SQLCODE List

Oracle SQLCODE ListThis page contains an Oracle SQLCODE list of errors that you may encounter when working with Oracle SQL. The codes are ANSI-standard, which means you should find them with all relational databases.

They will be returned by the SQLCODE function.

Oracle SQLCODE List

The list of SQLCODE messages is shown below. This content originally appeared at http://www.caliberdt.com/tips/sqlcode.htm.

Successful Execution

CodeExplanation
0Successful execution

 

Warnings

CodeExplanation
12The unqualified column name column-name was interpreted as a correlated reference
98A dynamic SQL statement ends with a semicolon
100Row not found for fetch, update or delete, or the result of a query is an empty table
110SQL update to a data capture table not signaled to originating subsystem
111The subpages option is not supported for type 2 indexes
117The number of insert values is not the same as the number of object columns
162Tablespace database-name.tablespace-name has been placed in check pending
203The qualified column name column-name was resolved using a non-unique or unexposed name
204name is an undefined name
206column-name is not a column of an inserted table, updated table, or any table identified in a from clause
218The SQL statement referencing a remote object cannot be explained
219The required explanation table table-name does not exist
220The column column-name in explanation table table-name is not defined properly
304A value with data type data-type1 cannot be assigned to a host variable because the value is not within the range of the host variable in position position-number with data type data-type2
331The NULL value has been assigned to a host variable because the string cannot be translated. reason reason-code, character code-point, host variable position-number
339The SQL statement has been successfully executed, but there may be some character conversion inconsistencies
402Location location is unknown
403The local object referenced by the create alias statement does not exist
535The result of the positioned update or delete may depend on the order of the rows.
541The referential or unique constraint name has been ignored because it is a duplicate
551auth-id does not have the privilege to perform operation operation on object object-name
552auth-id does not have the privilege to perform operation operation
558The with grant option is ignored
561The alter, index, and references privileges cannot be granted to public at all locations
562A grant of a privilege was ignored because the grantee already has the privilege from the grantor
610Index index-name has been placed in recover pending
625The definition of table table-name has been changed to incomplete
626Dropping the index terminates enforcement of the uniqueness of a key that was defined when the table was created
645Where not NULL is ignored because the index key cannot contain NULL values
650The table being created or altered cannot become a dependent table
653Table table-name in partitioned tablespace tspace-name is not available because its partitioned index has not been created
658The subpages value is ignored for the catalog index index-name
664The internal length of the limit-key fields for the partitioned index index-name exceeds the length imposed by the index manager
738Definition change of object object_name may require similar change on read-only systems
802Exception error exception-type has occurred during operation-type operation on data-type data, position position-number
806Bind isolation level rr conflicts with tablespace locksize page or locksize row and lockmax 0
807The result of decimal multiplication may cause overflow
863The connection was successful but only sbcs will be supported
2000Type 1 indexes with subpages greater than 1 cannot become group buffer pool dependent in a data sharing environment
30100Operation completed successfully but a distribution protocol violation has been detected. original SQLcode=original-SQLcode and original SQLstate=original-SQLstate

 

Errors

CodeExplanation
-7Statement contains the illegal character character
-10The string constant beginning string is not terminated
-29Into clause required
-60Invalid type specification : spec
-84Unacceptable SQL statement
-101The statement is too long or too complex
-102Literal string is too long. string begins string
-103literal is an invalid numeric literal
-104Illegal symbol “token”. some symbols that might be legal are: token-list
-105Invalid string
-107The name name is too long. maximum allowable size is size
-109clause clause is not permitted
-110Invalid hexadecimal literal beginning string
-111A column function does not include a column name
-112The operand of a column function is another column function
-113Invalid character found in string, reason code – nnn
-114The location name location does not match the current server
-115A predicate is invalid because the comparison operator operator is followed by a parenthesized list or by any or all without a subquery
-117The number of insert values is not the same as the number of object columns
-118The object table or view of the insert, delete, or update statement is also identified in a from clause
-119A column identified in a having clause is not included in the group by clause
-120A where clause or set clause includes a column function
-121The column name is identified more than once in the insert or update statement
-122A select statement with no group by clause contains a column name and a column function in the select clause or a column name is contained in the select clause but not in the group by clause
-125An integer in the order by clause does not identify a column of the result
-126The select statement contains both an update clause and an order by clause
-127Distinct is specified more than once in a subselect
-128Invalid use of NULL in a predicate
-129The statement contains too many table names
-130The escape clause consists of more than one character, or the string pattern contains an invalid occurrence of the escape character
-131Statement with like predicate has incompatible data types
-132A like predicate is invalid because the second operand is not a string
-133A column function in a subquery of a having clause is invalid because all column references in its argument are not correlated to the group by result that the having clause is applied to
-134Improper use of long string column column-name or a host variable of maximum length greater than 254
-136Sort cannot be executed because the sort key length is greater than 4000 bytes
-137Result of concatenation too long
-138The second or third argument of the substr function is out of range
-144Invalid section number number
-150The object of the insert, delete, or update statement is a view for which the requested operation is not permitted
-151The update statement is invalid because the catalog description of column column-name indicates that it cannot be updated
-152The drop clause clause in the alter statement is invalid because constraint-name is a constraint-type
-153The create view statement does not include a required column list
-154The create view failed because the view definition contains a union, a union all, or a remote object
-156The statement does not identify a table
-157Only a table name can be specified in a foreign key clause. object-name is not the name of a table.
-158The number of columns specified for the view is not the same as the number of columns specified by the select clause
-159Drop or comment on token identifies a(n) token rather than a(n) token
-160The with check option cannot be used for the specified view
-161The insert or update is not allowed because a resulting row does not satisfy the view definition
-164auth-id1 does not have the privilege to create a view with qualification authorization id
-170The number of arguments specified for function-name is invalid
-171The data type, length, or value of argument nn of function-name is invalid
-173UR is specified on the with clause but the cursor is not read-only
-180The string representation of a datetime value has invalid syntax
-181The string representation of a datetime value is not a valid datetime value
-182An arithmetic expression with a datetime value is invalid
-183An arithmetic operation on a date or timestamp has a result that is not within the valid range of dates
-184An arithmetic expression with a datetime value contains a parameter marker
-185The local format option has been used with a date or time and no local exit has been installed
-186The local date length or local time length has been increased and executing program relies on the old length
-187A reference to a current date/time special register is invalid because the mvs tod clock is bad or the mvs parmtz is out of range
-188The string representation of a name is invalid
-189Ccsid ccsid is unknown or invalid for the data type or subtype
-191A string cannot be used because it is invalid mixed data
-197Qualified column names in order by clause not permitted when union or union all specified
-198The operand of the prepare or execute immediate statement is blank or empty
-199Illegal use of keyword keyword. token token-list was expected
-203A reference to column column-name is ambiguous
-204name is an undefined name
-205column-name is not a column of table table-name
-206column-name is not a column of an inserted table, updated table, or any table identified in a from clause
-208The order by clause is invalid because column name is not part of the result table
-198The operand of the prepare or execute immediate statement is blank or empty
-199Illegal use of keyword keyword. token token-list was expected
-203A reference to column column-name is ambiguous
-204name is an undefined name
-205column-name is not a column of table table-name
-206column-name is not a column of an inserted table, updated table, or any table identified in a from clause
-208The order by clause is invalid because column name is not part of the result table
-219The required explanation table table-name does not exist
-220The column column-name in explanation table table-name is not defined properly
-221“set of optional columns” in explanation table table-name is incomplete. optional column column-name is missing
-250The local location name is not defined when processing a three-part object name
-251Token name is not valid
-300The string contained in host variable or parameter position-number is not nul-terminated
-301The value of input host variable or parameter number position-number cannot be used as specified because of its data type
-302The value of input variable or parameter number position-number is invalid or too large for the target column or the target value
-303A value cannot be assigned to output host variable number position-number because the data types are not comparable
-304A value with data type data-type1 cannot be assigned to a host variable because the value is not within the range of the host variable in position position-number with data type data-type2
-305The NULL value cannot be assigned to output host variable number position-number because no indicator variable is specified
-309A predicate is invalid because a referenced host variable has the NULL value
-310Decimal host variable or parameter number contains non decimal data.
-311The length of input host variable number position-number is negative or greater than the maximum
-312Undefined or unusable host variable variable-name
-313The number of host variables specified is not equal to the number of parameter markers
-314The statement contains an ambiguous host variable reference
-330A string cannot be used because it cannot be translated. reason reason-code, character code-point, host variable position-number
-331A string cannot be assigned to a host variable because it cannot be translated. reason reason-code, character code-point, position position-number
-332Sysstrings does not define a translation from ccsid ccsid to ccsid
-333The subtype of a string variable is not the same as the subtype known at bind time and the difference cannot be resolved by translation
-338An on clause is invalid
-339The SQL statement cannot be executed from an ascii based drda application requestor to a v2r2 db2 subsystem
-351An unsupported SQLtype was encountered in position “” on a prepare or describe operation
-400The catalog has the maximum number of user defined indexes
-401The operands of an arithmetic or comparison operation are not comparable
-402An arithmetic function or operator arith-fop is applied to character or datetime data
-404The update or insert statement specifies a string that is too long column-name
-405The numeric literal literal cannot be used as specified because it is out of range
-406A calculated or derived numeric value is not within the range of its object column
-407An update or insert value is NULL, but the object column column-name cannot contain NULL values
-408An update or insert value is not comparable with the data type of its object column column-name
-409Invalid operand of a count function
-410The floating point literal literal contains more than 30 characters
-411Current SQLid cannot be used in a statement that references remote objects
-412The select clause of a subquery specifies multiple columns
-414A like predicate is invalid because the first operand is not a string
-415The corresponding columns, column-number, of the operands of a union or a union all do not have comparable column descriptions
-416An operand of a union contains a long string column
-417A statement string to be prepared includes parameter markers as the operands of the same operator
-418A statement string to be prepared contains an invalid use of parameter markers
-419The decimal divide operation is invalid because the result would have a negative scale
-420The value of a character string argument was not acceptable to the function-name function
-421The operands of a union or union all do not have the same number of columns
-426Dynamic commit not valid at an application server where updates are not allowed
-427Dynamic rollback not valid at an application server where updates are not allowed
-440The number of parameters in the parameter list does not match the number of parameters expected for stored procedure name, authid authid, luname luname. number parameters were expected.
-444User program name could not be found
-450Stored procedure name, parameter number number, overlayed storage beyond its declared length
-469SQL call statement must specify an output host variable for parameter number.
-470SQL call statement specified a NULL value for input parameter number, but the stored procedure does not support NULL values
-471SQL call for stored procedure name failed due to reason rc
-500The identified cursor was closed when the connection was destroyed
-501The cursor identified in a fetch or close statement is not open
-502The cursor identified in an open statement is already open
-503A column cannot be updated because it is not identified in the update clause of the select statement of the cursor
-504The cursor name cursor-name is not defined
-507The cursor identified in the update or delete statement is not open
-508The cursor identified in the update or delete statement is not positioned on a row
-509The table identified in the update or delete statement is not the same table designated by the cursor
-510The table designated by the cursor of the update or delete statement cannot be modified
-511The for update clause cannot be specified because the table designated by the cursor cannot be modified
-512Statement reference to remote object is invalid
-513The alias alias-name must not be defined on another local or remote alias
-514The cursor cursor-name is not in a prepared state
-516The describe statement does not identify a prepared statement
-517Cursor cursor-name cannot be used because its statement name does not identify a prepared select statement
-518The execute statement does not identify a valid prepared statement
-519The prepare statement identifies the select statement of the opened cursor cursor-name
-525The SQL statement cannot be executed because it was in error at bind time for section = sectno package = pkgname consistency token = x’contoken’
-530The insert or update value of foreign key constraint-name is invalid
-531The primary key in a parent row cannot be updated because it has one or more dependent rows in relationship constraint-name
-532The relationship constraint-name restricts the deletion of row with rid x’rid-number’
-533Invalid multiple-row insert
-534The primary key cannot be updated because of multiple-row update
-536The delete statement is invalid because table table-name can be affected by the operation
-537The primary key clause, a foreign key clause, or a unique clause identifies column column-name more than once
-538Foreign key name does not conform to the description of the primary key of table table-name
-539Table table-name does not have a primary key
-540The definition of table table-name is incomplete because it lacks a primary index or a required unique index
-542column-name cannot be a column of a primary key or a unique constraint because it can contain NULL values
-543A row in a parent table cannot be deleted because the check constraint check-constraint restricts the deletion
-544The check constraint specified in the alter table statement cannot be added because an existing row violates the check constraint
-545The requested operation is not allowed because a row does not satisfy the check constraint check-constraint
-546The check constraint constraint-name is invalid
-548A check constraint that is defined with column-name is invalid
-549The statement statement is not allowed for object_type1 object_name because the bind option dynamicrules(bind) in the object_type2 is in effect
-551auth-id does not have the privilege to perform operation operation on object object-name
-552auth-id does not have the privilege to perform operation operation
-553auth-id specified is not one of the valid authorization ids
-554An authorization id cannot grant a privilege to itself
-555An authorization id cannot revoke a privilege from itself
-556authid2 cannot have the privilege privilege on_object revoked by authid1 because the revokee does not possess the privilege or the revoker did not make the grant
-557Inconsistent grant/revoke keyword keyword. permitted keywords are keyword-list
-558Invalid clause or combination of clauses on a grant or revoke
-559All authorization functions have been disabled
-567bind-type authorization error using auth-id authority package = package-name privilege = privilege
-571The statement would result in a multiple site update
-574The specified default value conflicts with the column definition.
-601The name of the object to be created is identical to the existing name name of the object type obj-type
-602Too many columns specified in a create index
-603A unique index cannot be created because the table contains rows which are duplicates with respect to the values of the identified columns
-604A column definition specifies an invalid length, precision, or scale attribute
-607Operation or option operation is not defined for this object
-611Only lockmax 0 can be specified when the lock size of the tablespace is tablespace or table
-612column-name is a duplicate column name
-613The primary key or a unique constraint is too long or has too many columns
-614The index cannot be created because the sum of the internal lengths of the identified columns is greater than the allowable maximum
-615operation-type is not allowed on a package in use
-616obj-type1 obj-name1 cannot be dropped because it is referenced by obj-type2 obj-name2
-617A type 1 index cannot be defined on a table in a table space with locksize row
-618Operation operation is not allowed on system databases
-619Operation disallowed because the work file database is not stopped
-620Keyword keyword in stmt type statement is not permitted for a table space in the work file database
-621Duplicate dbid dbid was detected and previously assigned to database-name
-622For mixed data is invalid because the mixed data install option is no
-623A clustering index already exists on table table-name
-624Table table-name already has a primary key
-625Table table-name does not have an index to enforce the uniqueness of the primary key
-626The alter statement is not executable because the page set is not stopped
-627The alter statement is invalid because the pageset has user-managed data sets
-628The clauses are mutually exclusive.
-629Set NULL cannot be specified because foreign key name cannot contain NULL values
-630The where not NULL specification is invalid for type 1 indexes
-631Foreign key name is too long or has too many columns
-632The table cannot be defined as a dependent of table-name because of delete rule restrictions
-633The delete rule must be delete-rule
-634The delete rule must not be cascade
-635The delete rules cannot be different or cannot be set NULL
-636The partitioning keys are not specified in ascending or descending order
-637Duplicate keyword keyword
-638Table table-name cannot be created because column definition is missing
-639A NULLable column of a foreign key with a delete rule of set NULL cannot be a column of the key of a partitioned index
-640Locksize row cannot be specified because table in this tablespace has type 1 index
-642Too many columns in unique constraints
-643Check constraint exceeds maximum allowable length
-644Invalid value specified for keyword keyword in stmt-type tatement
-646Table table-name cannot be created in partitioned/default table space tspace-name because it already contains a table
-647Bufferpool bp-name cannot be specified because it has not been activated
-650The alter index cannot be executed, reason reason
-651Table description exceeds maximum size of object descriptor.
-652Violation of installation defined edit or validation procedure proc-name
-653Table table-name in partitioned table space tspace-name is not available because its partitioned index has not been created
-655The create or alter stogroup is invalid because the storage group would have both specific and non-specific volume ids
-660Index index-name cannot be created on partitioned table space tspace-name because key limits are not specified
-661Index index-name cannot be created on partitioned table space tspace-name because the number of part specifications is not equal to the number of partitions of the table space
-662A partitioned index cannot be created on a non-partitioned table space tspace-name
-663The number of key limit values is either zero, or greater than the number of columns in the key of index index-name
-665The part clause of an alter statement is omitted or invalid
-666stmt-verb object cannot be executed because function is in progress
-667The clustering index for a partitioned table space cannot be explicitly dropped
-668The column cannot be added to the table because the table has an edit procedure
-669A table in a partitioned table space cannot be explicitly dropped
-670The record length of the table exceeds the page size limit
-671The bufferpool attribute of the table space cannot be altered as specified because it would change the page size of the table space
-672Operation drop not allowed on table table_name
-676A 32k page bufferpool may not be used for an index
-677Insufficient virtual storage for bufferpool expansion
-678The literal literal specified for the index limit key must conform to the data type data-type of the corresponding column column-name
-679The object name cannot be created because a drop is pending on the object
-680Too many columns specified for a table
-681Column column-name in violation of installation defined field procedure. rt: return-code, rs: reason-code, msg: message-token
-682Field procedure procedure-name could not be loaded
-683Invalid column type for fieldproc, bit data, sbcs data, or mixed data option, column-name
-684The length of literal list beginning string is too long
-685Invalid field type, column-name
-686Column defined with a field procedure can not compare with another column with different field procedure
-687Field types incomparable
-688Incorrect data returned from field procedure, column-name, msgno
-689Too many columns defined for a dependent table
-690The statement is rejected by data definition control support. reason reason-code
-691The required registration table table-name does not exist
-692The required unique index index-name for ddl registration table table-name does not exist
-693The column column-name in ddl registration table or index table-name (index-name) is not defined properly
-694The ddl statement cannot be executed because a drop is pending on the ddl registration table table-name
-713The replacement value for special-register is invalid
-715Program program-name with mark release-dependency-mark failed because it depends on functions of the release from which fallback has occurred
-716Program program-name precompiled with incorrect level for this release.
-717Bind-type for object-type object-name with mark release-dependency-mark failed because object-type depends on functions of the release from which fallback has occurred.
-718Rebind for package package-name failed because ibmreqd of ibmreqd is invalid
-719Bind add error using auth-id authority package package-name already exists
-720Bind error, attempting to replace package = package_name with version = version2 but this version already exists
-721Bind error for package = pkg-id contoken = ‘contoken’x is not unique so it cannot be created
-722Bind-type error using auth-id authority package package-name does not exist
-726Bind error attempting to replace package = . there are enable or disable entries currently associated with the package
-730The parent of a table in a read-only shared database must also be a table in a read-only shared database
-731User-defined dataset dsname must be defined with shareoptions(1,3)
-732The database is defined on this subsystem with the roshare read attribute but the table space or index space has not been defined on the owning subsystem
-733The description of a table space, index space, or table in a roshare read database must be consistent with its description in the owner system
-734The roshare attribute of a database cannot be altered from roshare read
-735Database dbid cannot be accessed because it is no longer a shared database
-736Invalid obid obid specified
-737Implicit table space not allowed
-741A work file database is already defined for member member-name
-742Dsndb07 is the implicit work file database
-751A stored procedure has been placed in must_rollback state due to SQL operation name
-752The connect statement is invalid because the process is not in the connectable state
-802Exception error ‘exception-type’ has occurred during ‘operation-type’ operation on ‘data-type’ data, position ‘position-number’
-803An inserted or updated value is invalid because the index in index space indexspace-name constrains columns of the table so no two rows can contain duplicate values in those columns. rid of existing row is x’rid’
-804An error was found in the application program input parameters for the SQL statement. reason reason
-805Dbrm or package name location-name.collection-id.dbrm-name.consistency -token not found in plan plan-name. reason reason
-807Access denied: package package-name is not enabled for access from connection-type connection-name
-808The connect statement is not consistent with the first connect statement
-811The result of an embedded select statement is a table of more than one row, or the result of the subquery of a basic predicate is more than one value
-812The SQL statement cannot be processed because a blank collection-id was found in the current packageset special register while trying to form a qualified package name for program program-name.consistency-token using plan plan-name
-815A group by or having clause is implicitly or explicitly specified in an embedded select statement or a subquery of a basic predicate
-817The SQL statement cannot be executed because the statement will result in a prohibited update operation
-818The precompiler-generated timestamp x in the load module is different from the bind timestamp y built from the dbrm z
-819The view cannot be processed because the length of its parse tree in the catalog is zero
-820The SQL statement cannot be processed because catalog-table contains a value that is not valid in this release
-822The SQLda contains an invalid data address or indicator variable address
-840Too many items returned in a select or insert list
-842A connection to location-name already exists
-843The set connection or release statement must specify an existing connection
-870The number of host variables in the statement is not equal to the number of descriptors
-900The SQL statement cannot be executed because the application process is not connected to an application server
-901Unsuccessful execution caused by a system error that does not preclude the successful execution of subsequent SQL statements
-902Pointer to the essential control block (ct/rda) has value 0, rebind required
-904Unsuccessful execution caused by an unavailable resource. reason reason-code, type of resource resource-type, and resource name resource-name
-905Unsuccessful execution due to resource limit being exceeded, resource name = resource-name limit = limit-amount1 cpu seconds (limit-amount2 service units) derived from limit-source
-906The SQL statement cannot be executed because this function is disabled due to a prior error
-908Bind-type error using auth-id authority bind, rebind or auto-rebind operation is not allowed
-909The object has been deleted
-910The SQL statement cannot access an object on which a drop or alter is pending
-911The current unit of work has been rolled back due to deadlock or timeout. reason reason-code, type of resource resource-type, and resource name resource-name
-913Unsuccessful execution caused by deadlock or timeout. reason code reason-code, type of resource resource-type, and resource name resource-name
-917Bind package failed
-918The SQL statement cannot be executed because a connection has been lost
-919A rollback operation is required
-922Authorization failure: error-type error. reason reason-code
-923Connection not established: db2 condition reason reason-code, type resource-type, name resource-name
-924Db2 connection internal error, function-code, return-code, reason-code
-925Commit not valid in ims/vs or cics environment
-926Rollback not valid in ims/vs or cics environment
-927The language interface (li) was called when the connecting environment was not established. the program should be invoked under the dsn command
-929Failure in a data capture exit: token
-939Rollback required due to unrequested rollback of a remote server
-947The SQL statement failed because it will change a table defined with data capture changes, but the data cannot be propagated
-948Distributed operation is invalid
-950The location name specified in the connect statement is invalid or not listed in the communications database
-965Stored procedure procname terminated abnormally
-2001The number of host variable parameters for a stored procedure is not equal to the number of expected host variable parameters. actual number SQLdanum, expected number opnum
-30000Execution failed due to a distribution protocol error that will not affect the successful execution of subsequent commands or SQL statements: reason reason-code (sub-code)
-30020Execution failed due to a distribution protocol error that caused deallocation of the conversation: reason
-30021Execution failed due to a distribution protocol error that will affect the successful execution of subsequent commands or SQL statements: manager manager at level level not supported error
-30030Commit request was unsuccessful, a distribution protocol violation has been detected, the conversation has been deallocated. original SQLcode=original-SQLcode and original SQLstate=original-SQLstate
-30040Execution failed due to unavailable resources that will not affect the successful execution of subsequent commands or SQL statements. reason type of resource resource name product id rdbname
-30041Execution failed due to unavailable resources that will affect the successful execution of subsequent commands and SQL statements reason type of resource resource name product id rdbname
-30050 command or SQL statement invalid while bind process in progress
-30051Bind process with specified package name and consistency token not active
-30052Program preparation assumptions are incorrect
-30053Owner authorization failure
-30060Rdb authorization failure
-30061Rdb not found
-30070 command not supported error
-30071 object not supported error
-30072: parameter not supported error
-30073: parameter value not supported error
-30074Reply message with codepoint (svrcod) not supported error
-30080Communication error code (subcode)
-30090Remote operation invalid for application execution environment

 

Want To Improve Your Oracle SQL?

Improve your Oracle SQL queries by signing up to my free 21-day Oracle Tips email course.

We won't send you spam. Unsubscribe at any time. Powered by ConvertKit