构造函数
方法
compileArrayWhere
-
参数
- model: MySQLModel
- condition: readonly Readonly<Record<string, DataValue>>[]
- logic: string = 'AND'
makeArrayWhere
-
makeArrayWhere( model: MySQLModel, condition: readonly Readonly<Record<string, DataValue>>[], logic?: string,): string
参数
- model: MySQLModel
- condition: readonly Readonly<Record<string, DataValue>>[]
- logic: string = 'AND'
返回 string
makeIndex
-
makeIndex(_model: MySQLModel, index?: string): string
makeLimit
-
makeLimit(_model: MySQLModel, limit: readonly (
string | number)
[]): string
参数
- _model: MySQLModel
- limit: readonly (string | number)[]
返回 string
makeOrder
-
makeOrder( model: MySQLModel, order: readonly Readonly<Record<string, number>>[],): string
参数
- model: MySQLModel
- order: readonly Readonly<Record<string, number>>[]
返回 string
makeWhere
-
makeWhere( model: MySQLModel, condition: | Readonly<Record<string, DataValue>> | readonly Readonly<Record<string, DataValue>>[], logic?: string,): string
把 Toshihiko 查询结构编译为 MySQL 语句。
compile*方法会返回参数化 SQL 和占位符值。make*方法会把这些语句格式化为字符串,以便兼容和记录日志。