bsql

package
v0.0.0-...-ce6676e Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToBsqlRows

func ToBsqlRows(rows *sql.Rows, brows *Rows) error

Types

type BatchSql

type BatchSql struct {
	Sql  string
	Args []interface{}
}

func NewBtchSql

func NewBtchSql(sql string, args ...interface{}) BatchSql

type CV

type CV map[string]interface{}

type Result

type Result struct {
	LastInsertId int64
	RowsAffected int64
}

type Row

type Row struct {
	Data     []string
	ColsMap  map[string]int
	ColsName []string
}

func FetchFirstRowE

func FetchFirstRowE(rows *sql.Rows) (*Row, error)

type Rows

type Rows struct {
	Count    int
	Data     [][]string
	ColsMap  map[string]int
	ColsName []string
}

func FetchRows

func FetchRows(rows *sql.Rows) *Rows

func FetchRowsE

func FetchRowsE(rows *sql.Rows) (*Rows, error)

func (*Rows) GetRow

func (rows *Rows) GetRow(rowNo int) *Row

func (*Rows) GetValue

func (rows *Rows) GetValue(rowNo int, colName string) string

func (*Rows) GetValueE

func (rows *Rows) GetValueE(rowNo int, colName string) (string, error)

type SqlExpr

type SqlExpr struct {
	Expr   string
	Values []interface{}
	Result string
	Err    error
}

func Expr

func Expr(expr string, args ...interface{}) (sqlExpr *SqlExpr)

Jump to

Keyboard shortcuts

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