UNPKG

tspace-mysql

Version:

Tspace MySQL is a promise-based ORM for Node.js, designed with modern TypeScript and providing type safety for schema databases.

109 lines (108 loc) 3.42 kB
import { QueryBuilder } from ".."; import { Blueprint } from "../../Blueprint"; import { StateManager } from "../../StateManager"; export declare class PostgresQueryBuilder extends QueryBuilder { constructor(state: StateManager); select: () => string; insert(): string; update(): string; remove(): string; any(): string; getColumns({ database, table }: { database: string; table: string; }): string; getSchema({ database, table }: { database: string; table: string; }): string; getTables(database: string): string; getTable({ database, table }: { database: string; table: string; }): string; createTable({ database, table, schema, }: { database: string; table: string; schema: Record<string, Blueprint> | string[]; }): string; addColumn({ table, column, type, attributes, after, }: { table: string; column: string; type: string; attributes: string[]; after: string; }): string; changeColumn({ table, column, type, attributes, }: { table: string; column: string; type: string; attributes: string[]; }): string; getChildFKs({ database, table }: { database: string; table: string; }): string; getFKs({ database, table }: { database: string; table: string; }): string; hasFK({ database, table, constraint, }: { database: string; table: string; constraint: string; }): string; createFK({ table, tableRef, key, constraint, foreign, }: { table: string; tableRef: string; key: string; constraint: string; foreign: { references: string; onDelete: string; onUpdate: string; }; }): string; dropFK({ table, constraint, }: { table: string; constraint: string; }): string; getIndexes({ database, table }: { database: string; table: string; }): string; hasIndex({ database, table, index, }: { database: string; table: string; index: string; }): string; createIndex({ table, index, key, }: { table: string; index: string; key: string; }): string; getDatabase(database: string): string; dropDatabase(database: string): string; dropView(view: string): string; dropTable(table: string): string; truncate(table: string): string; sleep(second: number): string; format(sql: (string | null)[] | string): string; protected bindJoin(values: string[]): string | null; protected bindWhere(values: string[]): string | null; protected bindOrderBy(values: string[]): string | null; protected bindGroupBy(values: string[]): string | null; protected bindSelect(values: string[], { distinct }?: { distinct?: string; }): string; protected bindFrom({ from, alias, rawAlias, }: { from: string[]; alias: string | null; rawAlias: string | null; }): string; protected bindLimit(limit: string | number | null): string; protected bindOffset(offset: string | number | null): string; protected bindHaving(having: string | null): string; protected bindRowLevelLock(mode: "FOR_UPDATE" | "FOR_SHARE" | null): any; private _formatedTypeAndAttributes; }