Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ErrorContains ¶
ErrorContains checks whether an error contains a needle.
func IsMysqlError ¶
func IsMysqlError(err error, mysqlErrorNumber MysqlErrorNumber) bool
IsMysqlError checks whether an error is a Mysql error of a certain type.
Types ¶
type MysqlErrorNumber ¶
type MysqlErrorNumber uint16
const ( DuplicateEntryError MysqlErrorNumber = 1062 LockDeadlockError MysqlErrorNumber = 1213 ForeignConstraintError MysqlErrorNumber = 1452 )
Click to show internal directories.
Click to hide internal directories.