Documentation ¶
Index ¶
- Variables
- func Database(dbName ...string) xqi.Database
- func Delete(table xqi.SqlTable, dbName ...string) xdelete.SqlDelete
- func DeleteByDb(table xqi.SqlTable, db xqi.Database) xdelete.SqlDelete
- func Insert(table xqi.SqlTable, dbName ...string) xinsert.SqlInsert
- func InsertByDb(table xqi.SqlTable, db xqi.Database) xinsert.SqlInsert
- func Query(dbName ...string) xqi.QuerySelect
- func QueryByDb(db xqi.Database) xqi.QuerySelect
- func Update(table xqi.SqlTable, dbName ...string) xupdate.SqlUpdate
- func UpdateByDb(table xqi.SqlTable, db xqi.Database) xupdate.SqlUpdate
- type DbType
- type SqlBaseTable
- type SqlCase
- type SqlCaseThenElse
- type SqlCondition
- type SqlConditionItem
- func Eq(exp1, exp2 interface{}) SqlConditionItem
- func Gt(exp1, exp2 interface{}) SqlConditionItem
- func Gte(exp1, exp2 interface{}) SqlConditionItem
- func In(exp, arr interface{}) SqlConditionItem
- func Like(exp, val interface{}) SqlConditionItem
- func Lt(exp1, exp2 interface{}) SqlConditionItem
- func Lte(exp1, exp2 interface{}) SqlConditionItem
- func Neq(exp1, exp2 interface{}) SqlConditionItem
- func Not(exp interface{}) SqlConditionItem
- func NotIn(exp, arr interface{}) SqlConditionItem
- func NotLike(exp, val interface{}) SqlConditionItem
- type SqlField
- type SqlFun
- type SqlLogic
- type SqlQuery
- type SqlTable
- type SqlTableField
- type SqlTables
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // 数据库int类型 DTInt = xqcomm2.DTInt // 数据库tinyint类型 DTTinyint = xqcomm2.DTTinyint // 数据库smallint类型 DTSmallint = xqcomm2.DTSmallint // 数据库bigint类型 DTBigint = xqcomm2.DTBigint // 数据库float类型 DTFloat = xqcomm2.DTFloat // 数据库double类型 DTDouble = xqcomm2.DTDouble // 数据库decimal类型 DTDecimal = xqcomm2.DTDecimal // 数据库date类型 DTDate = xqcomm2.DTDate // 数据库time类型 DTTime = xqcomm2.DTTime // 数据库datetime类型 DTDatetime = xqcomm2.DTDatetime // 数据库timestamp类型 DTTimestamp = xqcomm2.DTTimestamp // 数据库char类型 DTChar = xqcomm2.DTChar // 数据库varchar类型 DTVarchar = xqcomm2.DTVarchar // 数据库tinytext类型 DTTinytext = xqcomm2.DTTinytext // 数据库text类型 DTText = xqcomm2.DTText // 数据库longtext类型 DTLongtext = xqcomm2.DTLongtext // 数据库blob类型 DTBlob = xqcomm2.DTBlob // 数据库tinyblob类型 DTTinyblob = xqcomm2.DTTinyblob // 数据库longblob类型 DTLongblob = xqcomm2.DTLongblob // 数据库binary类型 DTBinary = xqcomm2.DTBinary // 数据库varbinary类型 DTVarbinary = xqcomm2.DTVarbinary )
数据库数据类型
View Source
var ( SFCase = xqcomm2.SqlFunCase SFSubstr = xqcomm2.SqlFunSubstring SFConcat = xqcomm2.SqlFunStrConcat SFDateFormat = xqcomm2.SqlFunDateFormat SFDateDiff = xqcomm2.SqlFunDateFormat SFDateAdd = xqcomm2.SqlFunDateAdd SFDateSub = xqcomm2.SqlFunDateSub SFDateToUnix = xqcomm2.SqlFunDateToUnix SFUnixToDate = xqcomm2.SqlFunUnixToDate SFIfNull = xqcomm2.SqlFunIfNull SFIsNull = xqcomm2.SqlFunIsNull SFIf = xqcomm2.SqlFunIf SFCast = xqcomm2.SqlFunCast )
sql 常用函数方法
View Source
var ( NewBaseTable = xqcomm2.NewSqlTable NewBaseField = xqcomm2.NewSqlTableField NewField = xqcomm2.NewSqlField RealValue = func(val interface{}, varName ...string) xqi.SqlVarExpr { return xqcomm2.NewSqlVar(nil, val, varName...) } NewSqlContext = xqcomm2.NewSqlCompileContext )
创建方法
Functions ¶
func InsertByDb ¶
在指定的数据库上向指定表插入数据
Types ¶
type SqlBaseTable ¶
type SqlCaseThenElse ¶
type SqlCaseThenElse = xqi.SqlCaseThenElse
type SqlCondition ¶
type SqlCondition = xqi.SqlCondition
type SqlConditionItem ¶
type SqlConditionItem = xqi.SqlConditionItem
func Eq ¶
func Eq(exp1, exp2 interface{}) SqlConditionItem
func Gt ¶
func Gt(exp1, exp2 interface{}) SqlConditionItem
func Gte ¶
func Gte(exp1, exp2 interface{}) SqlConditionItem
func In ¶
func In(exp, arr interface{}) SqlConditionItem
func Like ¶
func Like(exp, val interface{}) SqlConditionItem
func Lt ¶
func Lt(exp1, exp2 interface{}) SqlConditionItem
func Lte ¶
func Lte(exp1, exp2 interface{}) SqlConditionItem
func Neq ¶
func Neq(exp1, exp2 interface{}) SqlConditionItem
func Not ¶
func Not(exp interface{}) SqlConditionItem
func NotIn ¶
func NotIn(exp, arr interface{}) SqlConditionItem
func NotLike ¶
func NotLike(exp, val interface{}) SqlConditionItem
type SqlLogic ¶
type SqlLogic = xqi.SqlConditionLogic
type SqlTableField ¶
Click to show internal directories.
Click to hide internal directories.