EDB Postgres Advanced Server exceptions v15
List of server exceptions
The following table lists the predefined exceptions, the SQLstate values, associated redwood error code, and descriptions of the exceptions.
Exception name | SQLState | Redwood error code | Description |
---|---|---|---|
value_error | 22000 | -6502 | The exception occurs when the conversion of a character string to a number fails. |
invalid_number | 22000 | -6502 | The exception is raised in PL statement when the conversion of a character string to number fails. |
datetime_value_out_of_range | 22008 | -1863 | The exception occurs while writing a field in date format that is outside the valid range. |
divide_by_zero | 22012 | -1476 | The exception occurs when a program attempts to divide a number by zero. |
zero_divide | 22012 | -1476 | The exception occurs when a program attempts to divide a number by zero. |
dup_val_on_index | 23505 | -1 | The exception occurs when a program attempts to store duplicate values in a column that's constrained by a unique index. |
invalid_cursor | 34000 | -1001 | The exception occurs when a program attempts a cursor operation on an invalid cursor, such as closing an unopened cursor. |
cursor_already_open | 42P03 | -6511 | The exception occurs when a program attempts to open an already open cursor. |
collection_is_null | P1403 | -6531 | The exception occurs when a program attempts to assign values to the elements of nested table or varray that are uninitialized. |
subscript_beyond_count | P1404 | -6533 | The exception occurs when a program attempts to reference a nested table or varray using an index number larger than the number of elements in the collection. |
subscript_outside_limit | P1405 | -6532 | The exception occurs when a program attempts to reference a nested table or varray element using an index number that's outside the range. |
DBMS_CRYPTO package | |||
---|---|---|---|
ciphersuiteinvalid | 00009 | -28827 | The exception occurs when the cipher suite isn't defined. |
ciphersuitenull | 00009 | -28829 | The exception occurs when no value is specified for the cipher suite or it contains a NULL value. |
keybadsize | 00009 | 0 | The exception occurs when the specified key size is bad. |
keynull | 00009 | -28239 | The exception occurs when the key isn't specified. |
UTL_FILE package | |||
invalid_filehandle | P0001 00009 | -29282 | The exception occurs when file handle is invalid. |
invalid_maxlinesize | P0001 00009 | -29287 | The exception occurs when the max line size is invalid or the max line size value isn't within the range. |
invalid_mode | P0001 00009 | -29281 | The exception occurs when the open_mode parameter in FOPEN is invalid. |
invalid_operation | P0001 00009 | -29283 | The exception occurs when the file can't be opened or used upon request. |
invalid_path | P0001 00009 | -29280 | The exception occurs when the file location or file name is invalid. |
read_error | P0001 00009 | -29284 | The exception occurs when the operating system error occurred during the read operation. |
write_error | P0001 00009 | -29285 | The exception occurs when the operating system error occurred during the write operation. |
UTL_HTTP package | |||
end_of_body | P0001 00009 | -29266 | The exception occurs when the end of HTTP response body is reached. |
UTL_URL package | |||
bad_fixed_width_charset | 00009 | -29274 | The exception occurs when the fixed-width multibyte character isn't allowed as a URL character set. |
bad_url | P0001 00009 | -29262 | The exception occurs when the URL includes badly formed escape-code sequences. |
EDB Postgres Advanced Server keywords
A keyword is a word that's recognized by the EDB Postgres Advanced Server parser as having a special meaning or association. You can use the pg_get_keywords()
function to retrieve an up-to-date list of the EDB Postgres Advanced Server keywords:
pg_get_keywords
returns a table containing the keywords recognized by EDB Postgres Advanced Server:
- The
word
column displays the keyword. - The
catcode
column displays a category code. - The
catdesc
column displays a brief description of the category to which the keyword belongs.
You can use any character in an identifier if the name is enclosed in double quotes. You can selectively query the pg_get_keywords()
function to retrieve an up-to-date list of the EDB Postgres Advanced Server keywords that belong to a specific category:
Where code
is:
R
— The word is reserved. You can never use reserved keywords as an identifier. They are reserved for use by the server.
U
— The word is unreserved. Unreserved words are used internally in some contexts, but you can use them as a name for a database object.
T
— The word is used internally but can be used as a name for a function or type.
C
— The word is used internally and can't be used as a name for a function or type.
For more information about EDB Postgres Advanced Server identifiers and keywords, see the PostgreSQL core documentation.