@@ -6,7 +6,7 @@ use std::io::{Write, BufWriter};
66use std:: path:: Path ;
77use std:: convert:: AsRef ;
88
9- // From http://www.postgresql.org/docs/9.2 /static/errcodes-appendix.html
9+ // From http://www.postgresql.org/docs/9.5 /static/errcodes-appendix.html
1010const SQLSTATES : & ' static [ ( & ' static str , & ' static str ) ] = & [
1111 // Class 00 — Successful Completion
1212 ( "00000" , "SuccessfulCompletion" ) ,
@@ -93,6 +93,8 @@ const SQLSTATES: &'static [(&'static str, &'static str)] = &[
9393 ( "2201B" , "InvalidRegularExpression" ) ,
9494 ( "2201W" , "InvalidRowCountInLimitClause" ) ,
9595 ( "2201X" , "InvalidRowCountInResultOffsetClause" ) ,
96+ ( "2202H" , "InvalidTablesampleArgument" ) ,
97+ ( "2202G" , "InavlidTablesampleRepeat" ) ,
9698 ( "22009" , "InvalidTimeZoneDisplacementValue" ) ,
9799 ( "2200C" , "InvalidUseOfEscapeCharacter" ) ,
98100 ( "2200G" , "MostSpecificTypeMismatch" ) ,
@@ -181,6 +183,7 @@ const SQLSTATES: &'static [(&'static str, &'static str)] = &[
181183 ( "39004" , "NullValueNotAllowedExternalRoutine" ) ,
182184 ( "39P01" , "TriggerProtocolViolated" ) ,
183185 ( "39P02" , "SrfProtocolViolated" ) ,
186+ ( "39P03" , "EventTriggerProtocolViolated" ) ,
184187
185188 // Class 3B — Savepoint Exception
186189 ( "3B000" , "SavepointException" ) ,
@@ -318,6 +321,7 @@ const SQLSTATES: &'static [(&'static str, &'static str)] = &[
318321 ( "P0001" , "RaiseException" ) ,
319322 ( "P0002" , "NoDataFound" ) ,
320323 ( "P0003" , "TooManyRows" ) ,
324+ ( "P0004" , "AssertFailure" ) ,
321325
322326 // Class XX — Internal Error
323327 ( "XX000" , "InternalError" ) ,
0 commit comments