sql

package
v1.30.36 Latest Latest
Warning

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

Go to latest
Published: May 16, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// TableCols table columns map
	TableCols = cmap.NewCMap()
)

Functions

func GetKeySQL

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

GetKeySQL key search sql

func GetMoreKeySQL

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

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

func StructWhereSQL

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

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

func Table

func Table(table string) string

Table table parse

func TableOnly

func TableOnly(table string) string

TableOnly only table name

func TagTables added in v1.30.30

func TagTables(tag string, tables ...string) (tbs []string)

TagTables return tag tables

func UniqueTagTable

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

UniqueTagTable return unique tag table

Types

type Key

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