import { Sql, SQL_SYMBOLE } from '../../sql'; import { Field } from '../../expression'; import { XObjectName } from '../../object'; import { XWithSelect, WithSelect, XTables } from '../../rowset'; import { Scalar } from '../../scalar'; import { ColumnsOf, RowObject } from '../../types'; import { SelectAction } from './common/select-action'; import { Delete } from './delete'; import { Insert } from './insert'; import { Select } from './select'; import { Update } from './update'; export declare class With extends Sql { readonly $type: SQL_SYMBOLE.WITH; $rowsets: WithSelect[]; /** * With结构 */ constructor(...items: WithSelect[] | [WithSelect[]] | XWithSelect[] | [XWithSelect[]] | [SelectAliasObject]); /** * select查询 */ select: SelectAction; /** * 插入至表,into的别名 * @param table * @param fields */ insert(table: XObjectName | XTables, fields?: ColumnsOf[] | Field>[]): Insert; /** * 更新一个表格 * @param table */ update(table: XObjectName | XTables): Update; /** * 删除一个表格 * @param table 表格 */ delete(table: XObjectName | XTables): Delete; } export declare type SelectAliasObject = { [alias: string]: Select; };