package
0.0.0-20230930071117-b4c11361435a
Repository: https://github.com/d3code/pkg.git
Documentation: pkg.go.dev
# Functions
CanRetry returns true for every error in this package except ErrDupeKey.
Down returns true if the error indicates MySQL cannot be reached for any reason.
Duplicate returns true if is MySQL error and a duplicate.
Error returns an error in this package if possible.
ErrorCode returns the MySQL server error code for the error, or zero if the error is not a MySQL error.
Lost returns true if the error indicates the MySQL connection was lost.
NoRows returns true if no rows are found in result set.
# Variables
ErrCannotConnect is returned when a connection cannot be made because MySQL is unreachable for any reason.
ErrConnLost is returned when the connection is lost, closed, or killed for any reason.
ErrDupeKey is returned when a unique index prevents a value from being inserted or updated.
ErrQueryKilled is returned when the KILL QUERY command is used.
ErrReadOnly is returned when MySQL read-only is enabled.