pub enum PgError {
Show 43 variants
SuccessfulCompletion(PgErrorSuccessfulCompletion),
Warning(PgErrorWarning),
NoData(PgErrorNoData),
SqlStatementNotYetComplete(PgErrorSqlStatementNotYetComplete),
ConnectionException(PgErrorConnectionException),
TriggeredActionException(PgErrorTriggeredActionException),
FeatureNotSupported(PgErrorFeatureNotSupported),
InvalidTransactionInitiation(PgErrorInvalidTransactionInitiation),
LocatorException(PgErrorLocatorException),
InvalidGrantor(PgErrorInvalidGrantor),
InvalidRoleSpecification(PgErrorInvalidRoleSpecification),
DiagnosticsException(PgErrorDiagnosticsException),
CaseNotFound(PgErrorCaseNotFound),
CardinalityViolation(PgErrorCardinalityViolation),
DataException(PgErrorDataException),
IntegrityConstraintViolation(PgErrorIntegrityConstraintViolation),
InvalidCursorState(PgErrorInvalidCursorState),
InvalidTransactionState(PgErrorInvalidTransactionState),
InvalidSqlStatementName(PgErrorInvalidSqlStatementName),
TriggeredDataChangeViolation(PgErrorTriggeredDataChangeViolation),
InvalidAuthorizationSpecification(PgErrorInvalidAuthorizationSpecification),
DependentPrivilegeDescriptorsStillExist(PgErrorDependentPrivilegeDescriptorsStillExist),
InvalidTransactionTermination(PgErrorInvalidTransactionTermination),
SqlRoutineException(PgErrorSqlRoutineException),
InvalidCursorName(PgErrorInvalidCursorName),
ExternalRoutineException(PgErrorExternalRoutineException),
ExternalRoutineInvocationException(PgErrorExternalRoutineInvocationException),
SavepointException(PgErrorSavepointException),
InvalidCatalogName(PgErrorInvalidCatalogName),
InvalidSchemaName(PgErrorInvalidSchemaName),
TransactionRollback(PgErrorTransactionRollback),
SyntaxErrorOrAccessRuleViolation(PgErrorSyntaxErrorOrAccessRuleViolation),
WithCheckOptionViolation(PgErrorWithCheckOptionViolation),
InsufficientResources(PgErrorInsufficientResources),
ProgramLimitExceeded(PgErrorProgramLimitExceeded),
ObjectNotInPrerequisiteState(PgErrorObjectNotInPrerequisiteState),
OperatorIntervention(PgErrorOperatorIntervention),
SystemError(PgErrorSystemError),
ConfigFileError(PgErrorConfigFileError),
FdwError(PgErrorFdwError),
PlpgsqlError(PgErrorPlpgsqlError),
InternalError(PgErrorInternalError),
Other([u8; 5]),
}Expand description
Postgres error codes. See https://www.postgresql.org/docs/current/errcodes-appendix.html.
Variants§
SuccessfulCompletion(PgErrorSuccessfulCompletion)
Warning(PgErrorWarning)
NoData(PgErrorNoData)
SqlStatementNotYetComplete(PgErrorSqlStatementNotYetComplete)
ConnectionException(PgErrorConnectionException)
TriggeredActionException(PgErrorTriggeredActionException)
FeatureNotSupported(PgErrorFeatureNotSupported)
InvalidTransactionInitiation(PgErrorInvalidTransactionInitiation)
LocatorException(PgErrorLocatorException)
InvalidGrantor(PgErrorInvalidGrantor)
InvalidRoleSpecification(PgErrorInvalidRoleSpecification)
DiagnosticsException(PgErrorDiagnosticsException)
CaseNotFound(PgErrorCaseNotFound)
CardinalityViolation(PgErrorCardinalityViolation)
DataException(PgErrorDataException)
IntegrityConstraintViolation(PgErrorIntegrityConstraintViolation)
InvalidCursorState(PgErrorInvalidCursorState)
InvalidTransactionState(PgErrorInvalidTransactionState)
InvalidSqlStatementName(PgErrorInvalidSqlStatementName)
TriggeredDataChangeViolation(PgErrorTriggeredDataChangeViolation)
InvalidAuthorizationSpecification(PgErrorInvalidAuthorizationSpecification)
DependentPrivilegeDescriptorsStillExist(PgErrorDependentPrivilegeDescriptorsStillExist)
InvalidTransactionTermination(PgErrorInvalidTransactionTermination)
SqlRoutineException(PgErrorSqlRoutineException)
InvalidCursorName(PgErrorInvalidCursorName)
ExternalRoutineException(PgErrorExternalRoutineException)
ExternalRoutineInvocationException(PgErrorExternalRoutineInvocationException)
SavepointException(PgErrorSavepointException)
InvalidCatalogName(PgErrorInvalidCatalogName)
InvalidSchemaName(PgErrorInvalidSchemaName)
TransactionRollback(PgErrorTransactionRollback)
SyntaxErrorOrAccessRuleViolation(PgErrorSyntaxErrorOrAccessRuleViolation)
WithCheckOptionViolation(PgErrorWithCheckOptionViolation)
InsufficientResources(PgErrorInsufficientResources)
ProgramLimitExceeded(PgErrorProgramLimitExceeded)
ObjectNotInPrerequisiteState(PgErrorObjectNotInPrerequisiteState)
OperatorIntervention(PgErrorOperatorIntervention)
SystemError(PgErrorSystemError)
ConfigFileError(PgErrorConfigFileError)
FdwError(PgErrorFdwError)
PlpgsqlError(PgErrorPlpgsqlError)
InternalError(PgErrorInternalError)
Other([u8; 5])
Implementations§
Trait Implementations§
Source§impl Error for PgError
impl Error for PgError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl Ord for PgError
impl Ord for PgError
Source§impl PartialOrd for PgError
impl PartialOrd for PgError
impl Copy for PgError
impl Eq for PgError
impl StructuralPartialEq for PgError
Auto Trait Implementations§
impl Freeze for PgError
impl RefUnwindSafe for PgError
impl Send for PgError
impl Sync for PgError
impl Unpin for PgError
impl UnwindSafe for PgError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> EncoderForExt for Twhere
T: ?Sized,
impl<T> EncoderForExt for Twhere
T: ?Sized,
Source§fn to_vec<F>(&self) -> Vec<u8> ⓘwhere
F: 'static,
Self: EncoderFor<F>,
fn to_vec<F>(&self) -> Vec<u8> ⓘwhere
F: 'static,
Self: EncoderFor<F>,
Convert this builder into a vector of bytes. This is generally
not the most efficient way to perform serialization.
Source§fn encode_buffer<F>(&self, buf: &mut [u8]) -> Result<usize, usize>where
F: 'static,
Self: EncoderFor<F>,
fn encode_buffer<F>(&self, buf: &mut [u8]) -> Result<usize, usize>where
F: 'static,
Self: EncoderFor<F>,
Encode this builder into a given buffer. If the buffer is
too small, the function will return the number of bytes
required to encode the builder.
Source§fn encode_buffer_uninit<'a, F>(
&self,
buf: &'a mut [MaybeUninit<u8>],
) -> Result<&'a mut [u8], usize>where
F: 'static,
Self: EncoderFor<F>,
fn encode_buffer_uninit<'a, F>(
&self,
buf: &'a mut [MaybeUninit<u8>],
) -> Result<&'a mut [u8], usize>where
F: 'static,
Self: EncoderFor<F>,
Encode this builder into a given buffer. If the buffer is
too small, the function will return the number of bytes
required to encode the builder.