Scriptcase no data from table3/15/2024 Such names are supplied in separate fields of the error report message so that applications need not try to extract them from the possibly-localized human-readable text of the message. (Note that PL/pgSQL does not recognize warning, as opposed to error, condition names those are classes 00, 01, and 02.)įor some types of errors, the server reports the name of a database object (a table, table column, data type, or constraint) associated with the error for example, the name of the unique constraint that caused a unique_violation error. Condition names can be written in either upper or lower case. The symbol shown in the column “ Condition Name” is the condition name to use in PL/pgSQL. This code is used only for error conditions that fall within the class but do not have any more-specific code assigned. For each error class there is a “ standard” error code having the last three characters 000. (Some are not actually used at present, but are defined by the SQL standard.) The error classes are also shown. Table A.1 lists all the error codes defined in PostgreSQL 16.2. Thus, an application that does not recognize the specific error code might still be able to infer what to do from the error class. ![]() ![]() Note that some, but not all, of the error codes produced by PostgreSQL are defined by the SQL standard some additional error codes for conditions not defined by the standard have been invented or borrowed from other databases.Īccording to the standard, the first two characters of an error code denote a class of errors, while the last three characters indicate a specific condition within that class. ![]() The error codes are less likely to change across PostgreSQL releases, and also are not subject to change due to localization of error messages. Applications that need to know which error condition has occurred should usually test the error code, rather than looking at the textual error message. All messages emitted by the PostgreSQL server are assigned five-character error codes that follow the SQL standard's conventions for “ SQLSTATE” codes.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |