Documentation ¶
Overview ¶
Package xsql extends for the sql package. power by <Joshua Conero>(2020)
Package xsql extends for the sql package. power by <Joshua Conero>(2020)
Index ¶
- Constants
- type Builder
- func (c *Builder) Columns(columns ...string) *Builder
- func (c *Builder) Delete() *Builder
- func (c *Builder) GetSQL() (string, []any)
- func (c *Builder) GetTableString() string
- func (c *Builder) GroupBy(groupBys ...string) *Builder
- func (c *Builder) InnerJoin(table, cond string) *Builder
- func (c *Builder) Insert(data map[string]any) *Builder
- func (c *Builder) Join(table, cond, vtype string) *Builder
- func (c *Builder) LeftJoin(table, cond string) *Builder
- func (c *Builder) Limit(offset int, orRowCount ...int) *Builder
- func (c *Builder) OrderBy(orderBys ...string) *Builder
- func (c *Builder) Page(page int, orPageSize ...int) *Builder
- func (c *Builder) ResetBinds() *Builder
- func (c *Builder) ResetWhere(where string, binds ...any) *Builder
- func (c *Builder) RightJoin(table, cond string) *Builder
- func (c *Builder) Select(columns ...string) *Builder
- func (c *Builder) ToSQL() (string, []any)
- func (c *Builder) Update(data map[string]any) *Builder
- func (c *Builder) Where(where string, binds ...any) *Builder
- type Config
- type Query
- type Xsql
Constants ¶
View Source
const ( Version = "0.1.0" Release = "dev" Description = "concise and lightweight SQL builder." )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
Builder need to do. the sql builder
func (*Builder) GetTableString ¶
func (*Builder) ResetBinds ¶
type Query ¶
func (*Query) RowsDick ¶
RowsDick reference link: https://blog.csdn.net/weimingjue/article/details/91042649 get the rows dick database map to golang type:
INT int64 SMALLINT,TINYINT int DECIMAL float64 DATETIME,DATE time.Time; <!temp make to string> VARCHAR,CHAR,TEXT string
Click to show internal directories.
Click to hide internal directories.