mysql

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2020 License: MIT Imports: 17 Imported by: 1

Documentation

Index

Constants

View Source
const ErrDupEntry = 1062

ErrDupEntry MySQL Error 1062 indicates a duplicate primary key i.e. the row already exists, so we don't do the insert and return a ConditionalUpdate error.

View Source
const (
	// PluginName is the name of the plugin
	PluginName = "mysql"
)

Variables

This section is empty.

Functions

func GetTestClusterOption

func GetTestClusterOption() *pt.TestBaseOptions

GetTestClusterOption return test options

func NewDB

func NewDB(xdb *sqlx.DB, tx *sqlx.Tx) *db

NewDB returns an instance of DB, which is a logical connection to the underlying mysql database Fixme we need to ignore this Lint warning

Types

type DataConverter

type DataConverter interface {
	ToMySQLDateTime(t time.Time) time.Time
	FromMySQLDateTime(t time.Time) time.Time
}

DataConverter defines the API for conversions to/from go types to mysql datatypes

Jump to

Keyboard shortcuts

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