Documentation ¶
Index ¶
- Constants
- Variables
- type CacheConfig
- type Cnd
- func (self *Cnd) Agg(logic int, key string, alias ...string) *Cnd
- func (self *Cnd) Between(key string, value1 interface{}, value2 interface{}) *Cnd
- func (self *Cnd) Cache(config CacheConfig) *Cnd
- func (self *Cnd) Distinct(keys ...string) *Cnd
- func (self *Cnd) Eq(key string, value interface{}) *Cnd
- func (self *Cnd) Fields(keys ...string) *Cnd
- func (self *Cnd) From(fromTable string) *Cnd
- func (self *Cnd) Groupby(keys ...string) *Cnd
- func (self *Cnd) Gt(key string, value interface{}) *Cnd
- func (self *Cnd) Gte(key string, value interface{}) *Cnd
- func (self *Cnd) In(key string, values ...interface{}) *Cnd
- func (self *Cnd) IsNotNull(key string) *Cnd
- func (self *Cnd) IsNull(key string) *Cnd
- func (self *Cnd) Join(join int, table string, on string) *Cnd
- func (self *Cnd) Like(key string, value interface{}) *Cnd
- func (self *Cnd) Limit(pageNo int64, pageSize int64) *Cnd
- func (self *Cnd) Lt(key string, value interface{}) *Cnd
- func (self *Cnd) Lte(key string, value interface{}) *Cnd
- func (self *Cnd) NotBetween(key string, value1 interface{}, value2 interface{}) *Cnd
- func (self *Cnd) NotEq(key string, value interface{}) *Cnd
- func (self *Cnd) NotIn(key string, values ...interface{}) *Cnd
- func (self *Cnd) NotLike(key string, value interface{}) *Cnd
- func (self *Cnd) Offset(offset int64, limit int64) *Cnd
- func (self *Cnd) Or(cnds ...interface{}) *Cnd
- func (self *Cnd) Orderby(key string, sortby int) *Cnd
- func (self *Cnd) Summary(logic int, key string) *Cnd
- func (self *Cnd) UpdateKeyValue(keys []string, values ...interface{}) *Cnd
- type Condition
- type FromCond
- type JoinCond
Constants ¶
View Source
const ( EQ_ = iota NOT_EQ_ LT_ LTE_ GT_ GTE_ IS_NULL_ IS_NOT_NULL_ BETWEEN_ NOT_BETWEEN_ IN_ NOT_IN_ LIKE_ NO_TLIKE_ OR_ ORDER_BY_ ASC_ DESC_ LEFT_ RIGHT_ INNER_ SUM_ AVG_ MIN_ MAX_ CNT_ )
数据库操作类型枚举
Variables ¶
View Source
var ( Id = "Id" Ignore = "ignore" Bson = "bson" Json = "json" Mg = "mg" True = "true" BsonId = "id" Date = "date" )
Functions ¶
This section is empty.
Types ¶
type CacheConfig ¶
缓存结果集参数
type Cnd ¶
type Cnd struct { Conditions []Condition AnyFields []string Distincts []string Groupbys []string Orderbys []Condition Summaries map[string]int UpdateKV map[string]interface{} Model interface{} Pagination dialect.Dialect FromCond FromCond JoinCond []JoinCond CacheConfig CacheConfig Aggregates []Condition }
数据库操作汇总逻辑条件对象
func (*Cnd) NotBetween ¶
not between
func (*Cnd) UpdateKeyValue ¶
指定更新字段
Click to show internal directories.
Click to hide internal directories.