[DOCS] Table A-1. PostgreSQL Error Codes (WITH constants)
For easy COPY/PASTE, here goes (attached) a revisised "Table A-1. PostgreSQL Error Codes" with a new column "Constant". Best Regards. Mensagem enviada pelo Webmail UENF: http://www.grc.uenf.br/webmail Error Code Meaning Constant Class 00 Successful Completion 0 SUCCESSFUL COMPLETION successful_completion Class 01 Warning 1000 WARNING warning 0100C DYNAMIC RESULT SETS RETURNED dynamic_result_sets_returned 1008 IMPLICIT ZERO BIT PADDING implicit_zero_bit_padding 1003 NULL VALUE ELIMINATED IN SET FUNCTION null_value_eliminated_in_set_function 1007 PRIVILEGE NOT GRANTED privilege_not_granted 1006 PRIVILEGE NOT REVOKED privilege_not_revoked 1004 STRING DATA RIGHT TRUNCATION string_data_right_truncation 01P01 DEPRECATED FEATURE deprecated_feature Class 02 No Data this is also a warning class per the SQL standard 2000 NO DATA no_data 2001 NO ADDITIONAL DYNAMIC RESULT SETS RETURNED no_additional_dynamic_result_sets_returned Class 03 SQL Statement Not Yet Complete 3000 SQL STATEMENT NOT YET COMPLETE sql_statement_not_yet_complete Class 08 Connection Exception 8000 CONNECTION EXCEPTION connection_exception 8003 CONNECTION DOES NOT EXIST connection_does_not_exist 8006 CONNECTION FAILURE connection_failure 8001 SQLCLIENT UNABLE TO ESTABLISH SQLCONNECTION sqlclient_unable_to_establish_sqlconnection 8004 SQLSERVER REJECTED ESTABLISHMENT OF SQLCONNECTION sqlserver_rejected_establishment_of_sqlconnection 8007 TRANSACTION RESOLUTION UNKNOWN transaction_resolution_unknown 08P01 PROTOCOL VIOLATION protocol_violation Class 09 Triggered Action Exception 9000 TRIGGERED ACTION EXCEPTION triggered_action_exception Class 0A Feature Not Supported 0A000 FEATURE NOT SUPPORTED feature_not_supported Class 0B Invalid Transaction Initiation 0B000 INVALID TRANSACTION INITIATION invalid_transaction_initiation Class 0F Locator Exception 0F000 LOCATOR EXCEPTION locator_exception 0F001 INVALID LOCATOR SPECIFICATION invalid_locator_specification Class 0L Invalid Grantor 0L000 INVALID GRANTOR invalid_grantor 0LP01 INVALID GRANT OPERATION invalid_grant_operation Class 0P Invalid Role Specification 0P000 INVALID ROLE SPECIFICATION invalid_role_specification Class 21 Cardinality Violation 21000 CARDINALITY VIOLATION cardinality_violation Class 22 Data Exception 22000 DATA EXCEPTION data_exception 2202E ARRAY SUBSCRIPT ERROR array_subscript_error 22021 CHARACTER NOT IN REPERTOIRE character_not_in_repertoire 22008 DATETIME FIELD OVERFLOW datetime_field_overflow 22012 DIVISION BY ZERO division_by_zero 22005 ERROR IN ASSIGNMENT error_in_assignment 2200B ESCAPE CHARACTER CONFLICT escape_character_conflict 22022 INDICATOR OVERFLOW indicator_overflow 22015 INTERVAL FIELD OVERFLOW interval_field_overflow 2201E INVALID ARGUMENT FOR LOGARITHM invalid_argument_for_logarithm 2201F INVALID ARGUMENT FOR POWER FUNCTION invalid_argument_for_power_function 2201G INVALID ARGUMENT FOR WIDTH BUCKET FUNCTION invalid_argument_for_width_bucket_function 22018 INVALID CHARACTER VALUE FOR CAST invalid_character_value_for_cast 22007 INVALID DATETIME FORMAT invalid_datetime_format 22019 INVALID ESCAPE CHARACTER invalid_escape_character 2200D INVALID ESCAPE OCTET invalid_escape_octet 22025 INVALID ESCAPE SEQUENCE invalid_escape_sequence 22P06 NONSTANDARD USE OF ESCAPE CHARACTER nonstandard_use_of_escape_character 22010 INVALID INDICATOR PARAMETER VALUE invalid_indicator_parameter_value 22020 INVALID LIMIT VALUE invalid_limit_value 22023 INVALID PARAMETER VALUE invalid_parameter_value 2201B INVALID REGULAR _expression_ invalid_regular_expression 22009 INVALID TIME ZONE DISPLACEMENT VALUE invalid_time_zone_displacement_value 2200C INVALID USE OF ESCAPE CHARACTER invalid_use_of_escape_character 2200G
Re: [DOCS] Table A-1. PostgreSQL Error Codes (WITH constants)
[EMAIL PROTECTED] wrote: > For easy COPY/PASTE, here goes (attached) a revisised "Table A-1. PostgreSQL > Error Codes" with a new column "Constant". Uh, our documentation is in SGML, particularly doc/src/sgml/errcodes.sgml. Can you send a patch to that file or should I merge your HTML into there? -- Bruce Momjian| http://candle.pha.pa.us [email protected] | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup.| Newtown Square, Pennsylvania 19073 ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [DOCS] Table A-1. PostgreSQL Error Codes (WITH constants)
Bruce Momjian writes: > [EMAIL PROTECTED] wrote: >> For easy COPY/PASTE, here goes (attached) a revisised "Table A-1. PostgreSQL >> Error Codes" with a new column "Constant". > Uh, our documentation is in SGML, particularly > doc/src/sgml/errcodes.sgml. Can you send a patch to that file or should > I merge your HTML into there? What exactly is the point of the change at all? regards, tom lane ---(end of broadcast)--- TIP 6: explain analyze is your friend
Re: [DOCS] Table A-1. PostgreSQL Error Codes (WITH constants)
> What exactly is the point of the change at all? Take a typical line in the table: Error Code | Meaning 23502 | NOT NULL VIOLATION Now assume I want to catch this exception in a plpgsql function: CREATE OR REPLACE FUNCTION foo() /* boilerplate omitted */ EXCEPTION WHEN NOT_NULL_VIOLATION THEN RAISE WARNING 'Crikey!'; WHEN OTHERS THEN RAISE NOTICE 'Oh well, [%,%]', SQLSTATE, SQLERRM; Making the "Meaning" column almost-usable as the exception name is frustrating. This patch would allow people writing functions to copy and paste the exception names directly. It's not a big deal, but it would save some re-typing for people writing a lot of functions (me, for example). - Utiba Pty Ltd This message has been scanned for viruses and dangerous content by Utiba mail server and is believed to be clean. ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings
