xmysql

package module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2021 License: Apache-2.0 Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CanRetry

func CanRetry(err error) bool

CanRetry checks if a query could be retried on the base of given error.

func ErrorCode

func ErrorCode(err error) cgerrors.ErrorCode

ErrorCode gets the mysql based error code from input error.

func IsDuplicatedError

func IsDuplicatedError(err error) bool

IsDuplicatedError checks if given error states for the mysql duplicated input error.

Types

type MySQLDriver added in v0.0.16

type MySQLDriver struct {
	// contains filtered or unexported fields
}

MySQLDriver is the implementation of the MySQL based database.Driver.

func NewDriver

func NewDriver() *MySQLDriver

NewDriver creates a new error driver.

func (*MySQLDriver) CanRetry added in v0.0.16

func (m *MySQLDriver) CanRetry(err error) bool

CanRetry implements database.Driver interface.

func (*MySQLDriver) DriverName added in v0.0.16

func (m *MySQLDriver) DriverName() string

DriverName implements database.Driver interface.

func (*MySQLDriver) ErrorCode added in v0.0.16

func (m *MySQLDriver) ErrorCode(err error) cgerrors.ErrorCode

ErrorCode implements cgerrors.ErrorCoder interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL