Versions in this module Expand all Collapse all v1 v1.0.1 Jul 6, 2023 Changes in this version + var ErrParseHe3MetaConninfo = errors.New("he3_meta_conninfo format not correct") v1.0.0 Dec 2, 2022 Changes in this version + var ErrAddressNull = errors.New("address is nil") + var ErrBadConn = errors.New("connection was bad") + var ErrBlackSqlExist = errors.New("black sql has exist") + var ErrBlackSqlNotExist = errors.New("black sql has not exist") + var ErrCmdUnsupport = errors.New("command unsupport") + var ErrColsLenNotMatch = errors.New("insert or replace cols and values length not match") + var ErrConnIsFull = errors.New("connection is full") + var ErrConnIsNil = errors.New("connection is nil") + var ErrConnNotEqual = errors.New("the length of conns not equal sqls") + var ErrDatabaseClose = errors.New("database is close") + var ErrDateIllegal = errors.New("date format illegal") + var ErrDateRangeCount = errors.New("date range count is not equal") + var ErrDateRangeIllegal = errors.New("date range format illegal") + var ErrDeleteInMulti = errors.New("delete in multi node") + var ErrExecInMulti = errors.New("exec in multi node") + var ErrExprConvert = errors.New("expr fail to convert") + var ErrIRNoColumns = errors.New("insert or replace must specify columns") + var ErrIRNoShardingKey = errors.New("insert or replace not contain sharding key") + var ErrIgnoreSQL = errors.New("ignore this sql") + var ErrInsertInMulti = errors.New("insert in multi node") + var ErrInsertTooComplex = errors.New("insert is too complex") + var ErrInternalServer = errors.New("internal server error") + var ErrInvalidArgument = errors.New("argument is invalid") + var ErrInvalidCharset = errors.New("charset is invalid") + var ErrKeyOutOfRange = errors.New("shard key not in key range") + var ErrLocationsCount = errors.New("locations count is not equal") + var ErrMasterDown = errors.New("master is down") + var ErrMaxPoolIsFull = errors.New("db connection pool is full") + var ErrMultiShard = errors.New("insert or replace has multiple shard targets") + var ErrNoCriteria = errors.New("plan have no criteria") + var ErrNoDatabase = errors.New("no database") + var ErrNoDefaultNode = errors.New("no default node") + var ErrNoMasterConn = errors.New("no master connection") + var ErrNoMasterDB = errors.New("no master database") + var ErrNoPlan = errors.New("statement have no plan") + var ErrNoPlanRule = errors.New("statement have no plan rule") + var ErrNoRouteNode = errors.New("no route node") + var ErrNoSlaveConn = errors.New("no slave connection") + var ErrNoSlaveDB = errors.New("no slave database") + var ErrReplaceInMulti = errors.New("replace in multi node") + var ErrResultNil = errors.New("result is nil") + var ErrSQLNULL = errors.New("sql is null") + var ErrSelectInInsert = errors.New("select in insert not allowed") + var ErrSlaveDown = errors.New("slave is down") + var ErrSlaveExist = errors.New("slave has exist") + var ErrSlaveNotExist = errors.New("slave has not exist") + var ErrStmtConvert = errors.New("statement fail to convert") + var ErrSumColumnType = errors.New("sum column type error") + var ErrTransInMulti = errors.New("transaction in multi node") + var ErrUnsupportDbType = errors.New("unsupport db type") + var ErrUpdateInMulti = errors.New("update in multi node") + var ErrUpdateKey = errors.New("routing key in update expression") + func ErrFormat(str string, args ...interface{}) error + func ErrFormatStr(str string, args ...interface{}) error + func SafeToRetry(err error) bool + func Timeout(err error) bool + type PgError struct + Code string + ColumnName string + ConstraintName string + DataTypeName string + Detail string + File string + Hint string + InternalPosition int32 + InternalQuery string + Line int32 + Message string + Position int32 + Routine string + SchemaName string + Severity string + TableName string + Where string + func ErrorResponseToPgError(msg *pgproto3.ErrorResponse) *PgError + func (pe *PgError) Error() string + func (pe *PgError) SQLState() string