Versions in this module Expand all Collapse all v1 v1.3.0 Apr 17, 2024 Changes in this version + func Close() error + func Exec(query string, args ...interface{}) (data sql.Result, err error) + func ExecContext(query string, args ...interface{}) (data sql.Result, err error) + func GetContext(dest interface{}, query string, args ...interface{}) error + func OnInit(config map[string]interface{}, option ...Option) (err error) + func Query(query string, args ...interface{}) (data *sql.Rows, err error) + func QueryContext(query string, args ...interface{}) (data *sql.Rows, err error) + func QueryRowxContext(query string, args ...interface{}) (data *sqlx.Row) + func QueryxContext(query string, args ...interface{}) (data *sqlx.Rows, err error) + func SelectContext(dest interface{}, query string, args ...interface{}) error + type ISys interface + Close func() error + Exec func(query string, args ...interface{}) (data sql.Result, err error) + ExecContext func(query string, args ...interface{}) (data sql.Result, err error) + GetContext func(dest interface{}, query string, args ...interface{}) error + Query func(query string, args ...interface{}) (data *sql.Rows, err error) + QueryContext func(query string, args ...interface{}) (data *sql.Rows, err error) + QueryRowxContext func(query string, args ...interface{}) (data *sqlx.Row) + QueryxContext func(query string, args ...interface{}) (data *sqlx.Rows, err error) + SelectContext func(dest interface{}, query string, args ...interface{}) error + func NewSys(option ...Option) (sys ISys, err error) + type Option func(*Options) + func SetSqlType(v SqlType) Option + func SetSqlUrl(v string) Option + func SetTimeOut(v time.Duration) Option + type Options struct + SqlType SqlType + SqlUrl string + TimeOut time.Duration + type Sql struct + func (this *Sql) Close() error + func (this *Sql) Exec(query string, args ...interface{}) (data sql.Result, err error) + func (this *Sql) ExecContext(query string, args ...interface{}) (data sql.Result, err error) + func (this *Sql) GetContext(dest interface{}, query string, args ...interface{}) error + func (this *Sql) Query(query string, args ...interface{}) (data *sql.Rows, err error) + func (this *Sql) QueryContext(query string, args ...interface{}) (data *sql.Rows, err error) + func (this *Sql) QueryRowxContext(query string, args ...interface{}) (data *sqlx.Row) + func (this *Sql) QueryxContext(query string, args ...interface{}) (data *sqlx.Rows, err error) + func (this *Sql) SelectContext(dest interface{}, query string, args ...interface{}) error + type SqlType string + const DM + const MySql + const Oracle + const SqlServer