Documentation ¶
Index ¶
- func InTx(txFunc TxFunc, ormObj ...orm.Ormer) (err error)
- func ParseNoRowsErr(err error) error
- type SqlBuilder
- func (this *SqlBuilder) Alias(alias string) *SqlBuilder
- func (this *SqlBuilder) CountString() string
- func (this *SqlBuilder) Dec(fieldname string, step int) (result sql.Result, err error)
- func (this *SqlBuilder) Fields(fields string) *SqlBuilder
- func (this *SqlBuilder) Filter(field string, value interface{}) *SqlBuilder
- func (this *SqlBuilder) Inc(fieldname string, step int) (result sql.Result, err error)
- func (this *SqlBuilder) Limit(offset int, size int) *SqlBuilder
- func (this *SqlBuilder) Order(orderString string) *SqlBuilder
- func (this *SqlBuilder) Page(page, pageSize int) *SqlBuilder
- func (this *SqlBuilder) Params() []interface{}
- func (this *SqlBuilder) QueryCount() (int64, error)
- func (this *SqlBuilder) QueryRow(containers ...interface{}) error
- func (this *SqlBuilder) QueryRows(containers ...interface{}) error
- func (this *SqlBuilder) QueryScalar(scalar interface{}) error
- func (this *SqlBuilder) Quot(str string, escapePercent bool) string
- func (this *SqlBuilder) RawFilter(whereStr string, params ...interface{}) *SqlBuilder
- func (this *SqlBuilder) RawWhere(whereStr string, params ...interface{}) *SqlBuilder
- func (this *SqlBuilder) Reset(table string) *SqlBuilder
- func (this *SqlBuilder) String() string
- func (this *SqlBuilder) StringAndParams() (string, []interface{})
- func (this *SqlBuilder) Table(table string) *SqlBuilder
- func (this *SqlBuilder) Update(params orm.Params) (result sql.Result, err error)
- func (this *SqlBuilder) UpdateString(params orm.Params) string
- func (this *SqlBuilder) Where(field string, value interface{}) *SqlBuilder
- func (this *SqlBuilder) WhereString(includesWhere bool) string
- type SqlWhereBuilder
- func (this *SqlWhereBuilder) Add(field string, value interface{}) *SqlWhereBuilder
- func (this *SqlWhereBuilder) IsWhereEmpty() bool
- func (this *SqlWhereBuilder) Raw(whereStr string, values ...interface{}) *SqlWhereBuilder
- func (this *SqlWhereBuilder) Reset() *SqlWhereBuilder
- func (this *SqlWhereBuilder) WhereAndParams(includesWhere bool) (string, []interface{})
- func (this *SqlWhereBuilder) WhereString(includesWhere bool) string
- type TxFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseNoRowsErr ¶
Types ¶
type SqlBuilder ¶
type SqlBuilder struct {
// contains filtered or unexported fields
}
func NewSqlBuilder ¶
func NewSqlBuilder(table string) *SqlBuilder
func NewSqlBuilderWithOrm ¶
func NewSqlBuilderWithOrm(table string, o orm.Ormer) *SqlBuilder
func (*SqlBuilder) Alias ¶
func (this *SqlBuilder) Alias(alias string) *SqlBuilder
func (*SqlBuilder) CountString ¶
func (this *SqlBuilder) CountString() string
func (*SqlBuilder) Fields ¶
func (this *SqlBuilder) Fields(fields string) *SqlBuilder
func (*SqlBuilder) Filter ¶
func (this *SqlBuilder) Filter(field string, value interface{}) *SqlBuilder
func (*SqlBuilder) Limit ¶
func (this *SqlBuilder) Limit(offset int, size int) *SqlBuilder
func (*SqlBuilder) Order ¶
func (this *SqlBuilder) Order(orderString string) *SqlBuilder
func (*SqlBuilder) Page ¶
func (this *SqlBuilder) Page(page, pageSize int) *SqlBuilder
func (*SqlBuilder) Params ¶
func (this *SqlBuilder) Params() []interface{}
func (*SqlBuilder) QueryCount ¶
func (this *SqlBuilder) QueryCount() (int64, error)
func (*SqlBuilder) QueryRow ¶
func (this *SqlBuilder) QueryRow(containers ...interface{}) error
func (*SqlBuilder) QueryRows ¶
func (this *SqlBuilder) QueryRows(containers ...interface{}) error
func (*SqlBuilder) QueryScalar ¶
func (this *SqlBuilder) QueryScalar(scalar interface{}) error
func (*SqlBuilder) RawFilter ¶
func (this *SqlBuilder) RawFilter(whereStr string, params ...interface{}) *SqlBuilder
func (*SqlBuilder) RawWhere ¶
func (this *SqlBuilder) RawWhere(whereStr string, params ...interface{}) *SqlBuilder
func (*SqlBuilder) Reset ¶
func (this *SqlBuilder) Reset(table string) *SqlBuilder
func (*SqlBuilder) String ¶
func (this *SqlBuilder) String() string
func (*SqlBuilder) StringAndParams ¶
func (this *SqlBuilder) StringAndParams() (string, []interface{})
func (*SqlBuilder) Table ¶
func (this *SqlBuilder) Table(table string) *SqlBuilder
func (*SqlBuilder) UpdateString ¶
func (this *SqlBuilder) UpdateString(params orm.Params) string
func (*SqlBuilder) Where ¶
func (this *SqlBuilder) Where(field string, value interface{}) *SqlBuilder
func (*SqlBuilder) WhereString ¶
func (this *SqlBuilder) WhereString(includesWhere bool) string
type SqlWhereBuilder ¶
type SqlWhereBuilder struct {
// contains filtered or unexported fields
}
func NewSqlWhereBuilder ¶
func NewSqlWhereBuilder() *SqlWhereBuilder
func (*SqlWhereBuilder) Add ¶
func (this *SqlWhereBuilder) Add(field string, value interface{}) *SqlWhereBuilder
func (*SqlWhereBuilder) IsWhereEmpty ¶
func (this *SqlWhereBuilder) IsWhereEmpty() bool
func (*SqlWhereBuilder) Raw ¶
func (this *SqlWhereBuilder) Raw(whereStr string, values ...interface{}) *SqlWhereBuilder
func (*SqlWhereBuilder) Reset ¶
func (this *SqlWhereBuilder) Reset() *SqlWhereBuilder
func (this *SqlWhereBuilder) {
}
func (*SqlWhereBuilder) WhereAndParams ¶
func (this *SqlWhereBuilder) WhereAndParams(includesWhere bool) (string, []interface{})
func (*SqlWhereBuilder) WhereString ¶
func (this *SqlWhereBuilder) WhereString(includesWhere bool) string
Click to show internal directories.
Click to hide internal directories.