Documentation
¶
Index ¶
- Variables
- func Conn(ctx context.Context) (*sql.Conn, error)
- func ConnOrTx(ctx context.Context) (*sql.Conn, *sql.Tx, error)
- func New(options ...func(*mysql)) *sql.DB
- func WithDB(db string) func(*mysql)
- func WithHost(host string) func(*mysql)
- func WithPassword(password string) func(*mysql)
- func WithPort(port string) func(*mysql)
- func WithUser(user string) func(*mysql)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoDBInContext = errors.New("mysql: no db in context") ErrNoDBAndTxInContext = errors.New("mysql: no db and tx in context") )
Functions ¶
func WithPassword ¶
func WithPassword(password string) func(*mysql)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.