Documentation ¶
Index ¶
- type SqlConnPool
- func (p *SqlConnPool) Begin() (*SqlConnTransaction, error)
- func (p *SqlConnPool) Close() error
- func (p *SqlConnPool) Delete(deleteStr string, args ...interface{}) (int64, error)
- func (p *SqlConnPool) Insert(insertStr string, args ...interface{}) (int64, error)
- func (p *SqlConnPool) InsertMap(table string, m map[string]interface{}) (int64, error)
- func (p *SqlConnPool) Query(queryStr string, args ...interface{}) ([]map[string]interface{}, error)
- func (p *SqlConnPool) QueryPage(page *utils.PageTable, args ...interface{}) (*utils.PageData, error)
- func (p *SqlConnPool) Update(updateStr string, args ...interface{}) (int64, error)
- type SqlConnTransaction
- func (t *SqlConnTransaction) Commit() error
- func (t *SqlConnTransaction) Delete(deleteStr string, args ...interface{}) (int64, error)
- func (t *SqlConnTransaction) Insert(insertStr string, args ...interface{}) (int64, error)
- func (t *SqlConnTransaction) Query(queryStr string, args ...interface{}) ([]map[string]interface{}, error)
- func (t *SqlConnTransaction) Rollback() error
- func (t *SqlConnTransaction) Update(updateStr string, args ...interface{}) (int64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SqlConnPool ¶
var (
DB *SqlConnPool
)
func (*SqlConnPool) Close ¶
func (p *SqlConnPool) Close() error
func (*SqlConnPool) Delete ¶
func (p *SqlConnPool) Delete(deleteStr string, args ...interface{}) (int64, error)
func (*SqlConnPool) Insert ¶
func (p *SqlConnPool) Insert(insertStr string, args ...interface{}) (int64, error)
func (*SqlConnPool) InsertMap ¶
func (p *SqlConnPool) InsertMap(table string, m map[string]interface{}) (int64, error)
func (*SqlConnPool) Query ¶
func (p *SqlConnPool) Query(queryStr string, args ...interface{}) ([]map[string]interface{}, error)
type SqlConnTransaction ¶
func (*SqlConnTransaction) Commit ¶
func (t *SqlConnTransaction) Commit() error
func (*SqlConnTransaction) Delete ¶
func (t *SqlConnTransaction) Delete(deleteStr string, args ...interface{}) (int64, error)
func (*SqlConnTransaction) Insert ¶
func (t *SqlConnTransaction) Insert(insertStr string, args ...interface{}) (int64, error)
Click to show internal directories.
Click to hide internal directories.