sql

package
v1.30.8 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var TableCols = cmap.NewCMap()

table columns map

Functions

func GetKeySQL

func GetKeySQL(key string, model interface{}, alias string) (sqlKey string, argsKey []interface{})

key search sql

func GetMoreKeySQL

func GetMoreKeySQL(key string, model interface{}, tables ...string) (sqlKey string, argsKey []interface{})

more tables key search sql tables [table1:table1_alias] searModel : Model

func GetSQLError

func GetSQLError(error string) (err error)

sql CN prompt

func StructWhereSQL added in v1.8.6

func StructWhereSQL(st interface{}) (sql string, args []interface{})

struct to where sql return key1 = value1 and key2 = value2...

func Table added in v1.8.9

func Table(table string) string

table parse

func TableOnly added in v1.20.11

func TableOnly(table string) string

only table name

func UniqueTagTable added in v1.20.11

func UniqueTagTable(tag string, tables ...string) (table string)

return unique table tag

Types

type Key added in v1.20.1

type Key struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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