metal-orm 1.1.22 → 1.1.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +564 -575
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +196 -164
- package/dist/index.d.ts +196 -164
- package/dist/index.js +554 -575
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/core/dialect/abstract.ts +94 -417
- package/src/core/dialect/base/expression-compiler-registry.ts +254 -0
- package/src/core/dialect/base/function-table-formatter.ts +40 -78
- package/src/core/dialect/base/select-ast-normalizer.ts +61 -0
- package/src/core/dialect/base/sql-dialect.ts +84 -245
- package/src/core/dialect/base/standard-delete-compiler.ts +37 -0
- package/src/core/dialect/base/standard-insert-compiler.ts +49 -0
- package/src/core/dialect/base/standard-select-compiler.ts +82 -0
- package/src/core/dialect/base/standard-sql-services.ts +44 -0
- package/src/core/dialect/base/standard-sql-source-compiler.ts +88 -0
- package/src/core/dialect/base/standard-update-compiler.ts +53 -0
- package/src/core/dialect/capabilities/procedure-compiler.ts +30 -0
- package/src/core/dialect/dialect-factory.ts +3 -4
- package/src/core/dialect/mssql/index.ts +3 -2
- package/src/core/dialect/mysql/index.ts +3 -2
- package/src/core/dialect/postgres/index.ts +3 -2
- package/src/core/dialect/sqlite/index.ts +1 -7
- package/src/index.ts +10 -1
- package/src/orm/execute-procedure.ts +3 -2
- package/src/query-builder/procedure-call.ts +4 -18
package/dist/index.d.ts
CHANGED
|
@@ -1986,23 +1986,6 @@ interface HydrationMetadata {
|
|
|
1986
1986
|
[key: string]: unknown;
|
|
1987
1987
|
}
|
|
1988
1988
|
|
|
1989
|
-
type ProcedureDirection = 'in' | 'out' | 'inout';
|
|
1990
|
-
interface ProcedureRefNode {
|
|
1991
|
-
name: string;
|
|
1992
|
-
schema?: string;
|
|
1993
|
-
}
|
|
1994
|
-
interface ProcedureParamNode {
|
|
1995
|
-
name: string;
|
|
1996
|
-
direction: ProcedureDirection;
|
|
1997
|
-
value?: OperandNode;
|
|
1998
|
-
dbType?: string;
|
|
1999
|
-
}
|
|
2000
|
-
interface ProcedureCallNode {
|
|
2001
|
-
type: 'ProcedureCall';
|
|
2002
|
-
ref: ProcedureRefNode;
|
|
2003
|
-
params: ProcedureParamNode[];
|
|
2004
|
-
}
|
|
2005
|
-
|
|
2006
1989
|
/**
|
|
2007
1990
|
* Context provided to function renderers.
|
|
2008
1991
|
*/
|
|
@@ -2044,30 +2027,16 @@ interface TableFunctionStrategy {
|
|
|
2044
2027
|
getRenderer(key: string): TableFunctionRenderer | undefined;
|
|
2045
2028
|
}
|
|
2046
2029
|
|
|
2047
|
-
/**
|
|
2048
|
-
* Context for SQL compilation with parameter management
|
|
2049
|
-
*/
|
|
2030
|
+
/** Context for SQL compilation with parameter management. */
|
|
2050
2031
|
interface CompilerContext {
|
|
2051
|
-
/** Array of parameters */
|
|
2052
2032
|
params: unknown[];
|
|
2053
|
-
/** Function to add a parameter and get its placeholder */
|
|
2054
2033
|
addParameter(value: unknown): string;
|
|
2055
2034
|
}
|
|
2056
|
-
/**
|
|
2057
|
-
* Result of SQL compilation
|
|
2058
|
-
*/
|
|
2035
|
+
/** Result of SQL compilation. */
|
|
2059
2036
|
interface CompiledQuery {
|
|
2060
|
-
/** Generated SQL string */
|
|
2061
2037
|
sql: string;
|
|
2062
|
-
/** Parameters for the query */
|
|
2063
2038
|
params: unknown[];
|
|
2064
2039
|
}
|
|
2065
|
-
interface CompiledProcedureCall extends CompiledQuery {
|
|
2066
|
-
outParams: {
|
|
2067
|
-
source: 'none' | 'firstResultSet' | 'lastResultSet';
|
|
2068
|
-
names: string[];
|
|
2069
|
-
};
|
|
2070
|
-
}
|
|
2071
2040
|
interface SelectCompiler {
|
|
2072
2041
|
compileSelect(ast: SelectQueryNode): CompiledQuery;
|
|
2073
2042
|
}
|
|
@@ -2081,143 +2050,85 @@ interface DeleteCompiler {
|
|
|
2081
2050
|
compileDelete(ast: DeleteQueryNode): CompiledQuery;
|
|
2082
2051
|
}
|
|
2083
2052
|
/**
|
|
2084
|
-
*
|
|
2053
|
+
* Public dialect contract consumed by builders and the ORM runtime.
|
|
2054
|
+
* Optional backend features such as stored procedures live in dedicated
|
|
2055
|
+
* capability interfaces; mutation-wide behavior shared by the runtime stays
|
|
2056
|
+
* in this small core contract.
|
|
2057
|
+
*/
|
|
2058
|
+
interface Dialect extends SelectCompiler, InsertCompiler, UpdateCompiler, DeleteCompiler {
|
|
2059
|
+
quoteIdentifier(id: string): string;
|
|
2060
|
+
supportsDmlReturningClause(): boolean;
|
|
2061
|
+
}
|
|
2062
|
+
/**
|
|
2063
|
+
* Shared implementation infrastructure for SQL dialects.
|
|
2064
|
+
*
|
|
2065
|
+
* This is deliberately separate from the public Dialect contract: custom
|
|
2066
|
+
* dialects may extend this class, extend SqlDialectBase, or use composition.
|
|
2085
2067
|
*/
|
|
2086
|
-
declare abstract class
|
|
2087
|
-
/** Dialect identifier used for function rendering and formatting */
|
|
2068
|
+
declare abstract class DialectBase implements Dialect {
|
|
2088
2069
|
protected abstract readonly dialect: DialectName$1;
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2070
|
+
private readonly expressionCompilerRegistry;
|
|
2071
|
+
private readonly selectAstNormalizer;
|
|
2072
|
+
protected readonly functionStrategy: FunctionStrategy;
|
|
2073
|
+
protected readonly tableFunctionStrategy: TableFunctionStrategy;
|
|
2074
|
+
protected constructor(functionStrategy?: FunctionStrategy, tableFunctionStrategy?: TableFunctionStrategy);
|
|
2094
2075
|
compileSelect(ast: SelectQueryNode): CompiledQuery;
|
|
2095
2076
|
compileInsert(ast: InsertQueryNode): CompiledQuery;
|
|
2096
2077
|
compileUpdate(ast: UpdateQueryNode): CompiledQuery;
|
|
2097
2078
|
compileDelete(ast: DeleteQueryNode): CompiledQuery;
|
|
2098
|
-
abstract compileProcedureCall(ast: ProcedureCallNode): CompiledProcedureCall;
|
|
2099
2079
|
supportsDmlReturningClause(): boolean;
|
|
2100
|
-
/**
|
|
2101
|
-
* Compiles SELECT query AST to SQL (to be implemented by concrete dialects)
|
|
2102
|
-
* @param ast - Query AST
|
|
2103
|
-
* @param ctx - Compiler context
|
|
2104
|
-
* @returns SQL string
|
|
2105
|
-
*/
|
|
2106
2080
|
protected abstract compileSelectAst(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
2107
2081
|
protected abstract compileInsertAst(ast: InsertQueryNode, ctx: CompilerContext): string;
|
|
2108
2082
|
protected abstract compileUpdateAst(ast: UpdateQueryNode, ctx: CompilerContext): string;
|
|
2109
2083
|
protected abstract compileDeleteAst(ast: DeleteQueryNode, ctx: CompilerContext): string;
|
|
2110
|
-
/**
|
|
2111
|
-
* Quotes an SQL identifier (to be implemented by concrete dialects)
|
|
2112
|
-
* @param id - Identifier to quote
|
|
2113
|
-
* @returns Quoted identifier
|
|
2114
|
-
*/
|
|
2115
2084
|
abstract quoteIdentifier(id: string): string;
|
|
2116
|
-
/**
|
|
2117
|
-
* Compiles a WHERE clause
|
|
2118
|
-
* @param where - WHERE expression
|
|
2119
|
-
* @param ctx - Compiler context
|
|
2120
|
-
* @returns SQL WHERE clause or empty string
|
|
2121
|
-
*/
|
|
2122
2085
|
protected compileWhere(where: ExpressionNode | undefined, ctx: CompilerContext): string;
|
|
2123
2086
|
protected compileReturning(returning: ColumnNode[] | undefined, _ctx: CompilerContext): string;
|
|
2124
|
-
/**
|
|
2125
|
-
* Generates subquery for EXISTS expressions
|
|
2126
|
-
* Rule: Always forces SELECT 1, ignoring column list
|
|
2127
|
-
* Maintains FROM, JOINs, WHERE, GROUP BY, ORDER BY, LIMIT/OFFSET
|
|
2128
|
-
* Does not add ';' at the end
|
|
2129
|
-
* @param ast - Query AST
|
|
2130
|
-
* @param ctx - Compiler context
|
|
2131
|
-
* @returns SQL for EXISTS subquery
|
|
2132
|
-
*/
|
|
2133
2087
|
protected compileSelectForExists(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
2134
|
-
/**
|
|
2135
|
-
* Creates a new compiler context
|
|
2136
|
-
* @returns Compiler context with parameter management
|
|
2137
|
-
*/
|
|
2138
2088
|
protected createCompilerContext(): CompilerContext;
|
|
2139
|
-
/**
|
|
2140
|
-
* Formats a parameter placeholder
|
|
2141
|
-
* @param index - Parameter index
|
|
2142
|
-
* @returns Formatted placeholder string
|
|
2143
|
-
*/
|
|
2144
2089
|
protected formatPlaceholder(_index: number): string;
|
|
2145
|
-
/**
|
|
2146
|
-
* Whether the current dialect supports a given set operation.
|
|
2147
|
-
* Override in concrete dialects to restrict support.
|
|
2148
|
-
*/
|
|
2149
2090
|
protected supportsSetOperation(_kind: SetOperationKind): boolean;
|
|
2150
|
-
/**
|
|
2151
|
-
* Validates set-operation semantics:
|
|
2152
|
-
* - Ensures the dialect supports requested operators.
|
|
2153
|
-
* - Enforces that only the outermost compound query may have ORDER/LIMIT/OFFSET.
|
|
2154
|
-
* @param ast - Query to validate
|
|
2155
|
-
* @param isOutermost - Whether this node is the outermost compound query
|
|
2156
|
-
*/
|
|
2157
|
-
protected validateSetOperations(ast: SelectQueryNode, isOutermost?: boolean): void;
|
|
2158
|
-
/**
|
|
2159
|
-
* Hoists CTEs from set-operation operands to the outermost query so WITH appears once.
|
|
2160
|
-
* @param ast - Query AST
|
|
2161
|
-
* @returns Normalized AST without inner CTEs and a list of hoisted CTEs
|
|
2162
|
-
*/
|
|
2163
|
-
private hoistCtes;
|
|
2164
|
-
/**
|
|
2165
|
-
* Normalizes a SELECT AST before compilation (validation + CTE hoisting).
|
|
2166
|
-
* @param ast - Query AST
|
|
2167
|
-
* @returns Normalized query AST
|
|
2168
|
-
*/
|
|
2169
2091
|
protected normalizeSelectAst(ast: SelectQueryNode): SelectQueryNode;
|
|
2170
|
-
private readonly expressionCompilers;
|
|
2171
|
-
private readonly operandCompilers;
|
|
2172
|
-
protected readonly functionStrategy: FunctionStrategy;
|
|
2173
|
-
protected readonly tableFunctionStrategy: TableFunctionStrategy;
|
|
2174
|
-
protected constructor(functionStrategy?: FunctionStrategy, tableFunctionStrategy?: TableFunctionStrategy);
|
|
2175
|
-
/**
|
|
2176
|
-
* Creates a new Dialect instance (for testing purposes)
|
|
2177
|
-
* @param functionStrategy - Optional function strategy
|
|
2178
|
-
* @returns New Dialect instance
|
|
2179
|
-
*/
|
|
2180
|
-
static create(functionStrategy?: FunctionStrategy, tableFunctionStrategy?: TableFunctionStrategy): Dialect;
|
|
2181
|
-
/**
|
|
2182
|
-
* Registers an expression compiler for a specific node type
|
|
2183
|
-
* @param type - Expression node type
|
|
2184
|
-
* @param compiler - Compiler function
|
|
2185
|
-
*/
|
|
2186
2092
|
protected registerExpressionCompiler<T extends ExpressionNode>(type: T['type'], compiler: (node: T, ctx: CompilerContext) => string): void;
|
|
2187
|
-
/**
|
|
2188
|
-
* Registers an operand compiler for a specific node type
|
|
2189
|
-
* @param type - Operand node type
|
|
2190
|
-
* @param compiler - Compiler function
|
|
2191
|
-
*/
|
|
2192
2093
|
protected registerOperandCompiler<T extends OperandNode>(type: T['type'], compiler: (node: T, ctx: CompilerContext) => string): void;
|
|
2193
|
-
/**
|
|
2194
|
-
* Compiles an expression node
|
|
2195
|
-
* @param node - Expression node to compile
|
|
2196
|
-
* @param ctx - Compiler context
|
|
2197
|
-
* @returns Compiled SQL expression
|
|
2198
|
-
*/
|
|
2199
2094
|
protected compileExpression(node: ExpressionNode, ctx: CompilerContext): string;
|
|
2200
|
-
/**
|
|
2201
|
-
* Compiles an operand node
|
|
2202
|
-
* @param node - Operand node to compile
|
|
2203
|
-
* @param ctx - Compiler context
|
|
2204
|
-
* @returns Compiled SQL operand
|
|
2205
|
-
*/
|
|
2206
2095
|
protected compileOperand(node: OperandNode, ctx: CompilerContext): string;
|
|
2207
|
-
/**
|
|
2208
|
-
* Compiles an ordering term (operand, expression, or alias reference).
|
|
2209
|
-
*/
|
|
2210
2096
|
protected compileOrderingTerm(term: OrderingTerm, ctx: CompilerContext): string;
|
|
2211
|
-
private registerDefaultExpressionCompilers;
|
|
2212
|
-
private registerDefaultOperandCompilers;
|
|
2213
2097
|
protected compileJsonPath(_node: JsonPathNode): string;
|
|
2214
|
-
/**
|
|
2215
|
-
* Compiles a function operand, using the dialect's function strategy.
|
|
2216
|
-
*/
|
|
2217
2098
|
protected compileFunctionOperand(fnNode: FunctionNode, ctx: CompilerContext): string;
|
|
2099
|
+
/** Creates a minimal dialect implementation for isolated compiler tests. */
|
|
2100
|
+
static create(functionStrategy?: FunctionStrategy, tableFunctionStrategy?: TableFunctionStrategy): Dialect;
|
|
2218
2101
|
}
|
|
2219
2102
|
|
|
2220
2103
|
type DialectKey = 'postgres' | 'mysql' | 'sqlite' | 'mssql' | (string & {});
|
|
2104
|
+
type DialectFactoryFn = () => Dialect;
|
|
2105
|
+
declare class DialectFactory {
|
|
2106
|
+
private static registry;
|
|
2107
|
+
private static defaultsInitialized;
|
|
2108
|
+
private static ensureDefaults;
|
|
2109
|
+
/**
|
|
2110
|
+
* Register (or override) a dialect factory for a key.
|
|
2111
|
+
*
|
|
2112
|
+
* Implementations are structural: extending DialectBase/SqlDialectBase is
|
|
2113
|
+
* optional. A composed object satisfying Dialect is a valid registration.
|
|
2114
|
+
*/
|
|
2115
|
+
static register(key: DialectKey, factory: DialectFactoryFn): void;
|
|
2116
|
+
/**
|
|
2117
|
+
* Resolve a key into a Dialect instance.
|
|
2118
|
+
* Throws if the key is not registered.
|
|
2119
|
+
*/
|
|
2120
|
+
static create(key: DialectKey): Dialect;
|
|
2121
|
+
/**
|
|
2122
|
+
* Clear all registrations (mainly for tests).
|
|
2123
|
+
* Built-ins will be re-registered lazily on the next create().
|
|
2124
|
+
*/
|
|
2125
|
+
static clear(): void;
|
|
2126
|
+
}
|
|
2127
|
+
/**
|
|
2128
|
+
* Helper to normalize either a Dialect instance OR a key into a Dialect instance.
|
|
2129
|
+
* This is what query builders will use.
|
|
2130
|
+
*/
|
|
2131
|
+
declare const resolveDialectInput: (dialect: Dialect | DialectKey) => Dialect;
|
|
2221
2132
|
|
|
2222
2133
|
/**
|
|
2223
2134
|
* Node types that can be used in query projections
|
|
@@ -5904,6 +5815,42 @@ declare class DeleteQueryBuilder<T> {
|
|
|
5904
5815
|
getAST(): DeleteQueryNode;
|
|
5905
5816
|
}
|
|
5906
5817
|
|
|
5818
|
+
type ProcedureDirection = 'in' | 'out' | 'inout';
|
|
5819
|
+
interface ProcedureRefNode {
|
|
5820
|
+
name: string;
|
|
5821
|
+
schema?: string;
|
|
5822
|
+
}
|
|
5823
|
+
interface ProcedureParamNode {
|
|
5824
|
+
name: string;
|
|
5825
|
+
direction: ProcedureDirection;
|
|
5826
|
+
value?: OperandNode;
|
|
5827
|
+
dbType?: string;
|
|
5828
|
+
}
|
|
5829
|
+
interface ProcedureCallNode {
|
|
5830
|
+
type: 'ProcedureCall';
|
|
5831
|
+
ref: ProcedureRefNode;
|
|
5832
|
+
params: ProcedureParamNode[];
|
|
5833
|
+
}
|
|
5834
|
+
|
|
5835
|
+
interface CompiledProcedureCall extends CompiledQuery {
|
|
5836
|
+
outParams: {
|
|
5837
|
+
source: 'none' | 'firstResultSet' | 'lastResultSet';
|
|
5838
|
+
names: string[];
|
|
5839
|
+
};
|
|
5840
|
+
}
|
|
5841
|
+
/**
|
|
5842
|
+
* Optional dialect capability for stored-procedure compilation.
|
|
5843
|
+
*
|
|
5844
|
+
* Dialects that do not support procedures simply do not implement this
|
|
5845
|
+
* interface; unsupported behavior is resolved at the capability boundary
|
|
5846
|
+
* rather than through mandatory methods that only throw.
|
|
5847
|
+
*/
|
|
5848
|
+
interface ProcedureCompiler {
|
|
5849
|
+
compileProcedureCall(ast: ProcedureCallNode): CompiledProcedureCall;
|
|
5850
|
+
}
|
|
5851
|
+
declare const isProcedureCompiler: (value: unknown) => value is ProcedureCompiler;
|
|
5852
|
+
declare const requireProcedureCompiler: (value: unknown) => ProcedureCompiler;
|
|
5853
|
+
|
|
5907
5854
|
interface ProcedureExecutionResult {
|
|
5908
5855
|
resultSets: QueryResult[];
|
|
5909
5856
|
out: Record<string, unknown>;
|
|
@@ -5928,7 +5875,6 @@ declare class ProcedureCallBuilder {
|
|
|
5928
5875
|
toSql(dialect: ProcedureDialectInput): string;
|
|
5929
5876
|
getAST(): ProcedureCallNode;
|
|
5930
5877
|
execute(session: OrmSession): Promise<ProcedureExecutionResult>;
|
|
5931
|
-
private validateMssqlOutDbType;
|
|
5932
5878
|
}
|
|
5933
5879
|
declare const callProcedure: (name: string, options?: CallProcedureOptions) => ProcedureCallBuilder;
|
|
5934
5880
|
|
|
@@ -6008,6 +5954,95 @@ interface PaginationStrategy {
|
|
|
6008
5954
|
compilePagination(limit?: number, offset?: number): string;
|
|
6009
5955
|
}
|
|
6010
5956
|
|
|
5957
|
+
/**
|
|
5958
|
+
* Narrow callback surface consumed by the standard SQL compilers.
|
|
5959
|
+
*
|
|
5960
|
+
* The compilers deliberately know nothing about SqlDialectBase or any concrete
|
|
5961
|
+
* backend class. A dialect can assemble these services through inheritance,
|
|
5962
|
+
* composition, or a plain object.
|
|
5963
|
+
*/
|
|
5964
|
+
interface StandardSqlCompilerServices {
|
|
5965
|
+
getDialectName(): DialectName$1;
|
|
5966
|
+
getPaginationStrategy(): PaginationStrategy;
|
|
5967
|
+
getTableFunctionStrategy(): TableFunctionStrategy;
|
|
5968
|
+
quoteIdentifier(id: string): string;
|
|
5969
|
+
compileOperand(node: OperandNode, ctx: CompilerContext): string;
|
|
5970
|
+
compileExpression(node: ExpressionNode, ctx: CompilerContext): string;
|
|
5971
|
+
compileOrderingTerm(term: OrderingTerm, ctx: CompilerContext): string;
|
|
5972
|
+
normalizeSelectAst(ast: SelectQueryNode): SelectQueryNode;
|
|
5973
|
+
compileSelectAst(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
5974
|
+
compileReturning(returning: ColumnNode[] | undefined, ctx: CompilerContext): string;
|
|
5975
|
+
compileUpsertClause(ast: InsertQueryNode, ctx: CompilerContext): string;
|
|
5976
|
+
compileSetTarget(column: ColumnNode, table: TableNode): string;
|
|
5977
|
+
renderOrderByNulls(order: OrderByNode): string | undefined;
|
|
5978
|
+
renderOrderByCollation(order: OrderByNode): string | undefined;
|
|
5979
|
+
}
|
|
5980
|
+
|
|
5981
|
+
/** Shared FROM/table-source rendering used by the standard query compilers. */
|
|
5982
|
+
declare class StandardSqlSourceCompiler {
|
|
5983
|
+
private readonly services;
|
|
5984
|
+
constructor(services: StandardSqlCompilerServices);
|
|
5985
|
+
compileFrom(source: TableSourceNode, ctx?: CompilerContext): string;
|
|
5986
|
+
compileFunctionTable(fn: FunctionTableNode, ctx?: CompilerContext): string;
|
|
5987
|
+
compileDerivedTable(table: DerivedTableNode, ctx?: CompilerContext): string;
|
|
5988
|
+
compileTableSource(table: TableSourceNode): string;
|
|
5989
|
+
compileTableName(table: {
|
|
5990
|
+
name: string;
|
|
5991
|
+
schema?: string;
|
|
5992
|
+
}): string;
|
|
5993
|
+
compileTableReference(table: {
|
|
5994
|
+
name: string;
|
|
5995
|
+
schema?: string;
|
|
5996
|
+
alias?: string;
|
|
5997
|
+
}): string;
|
|
5998
|
+
stripTrailingSemicolon(sql: string): string;
|
|
5999
|
+
wrapSetOperand(sql: string): string;
|
|
6000
|
+
}
|
|
6001
|
+
|
|
6002
|
+
/** Standard SELECT orchestration, independent from any dialect class hierarchy. */
|
|
6003
|
+
declare class StandardSelectCompiler {
|
|
6004
|
+
private readonly services;
|
|
6005
|
+
private readonly sources;
|
|
6006
|
+
constructor(services: StandardSqlCompilerServices, sources: StandardSqlSourceCompiler);
|
|
6007
|
+
compile(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
6008
|
+
private compileCore;
|
|
6009
|
+
private compileColumns;
|
|
6010
|
+
private compileOrderBy;
|
|
6011
|
+
}
|
|
6012
|
+
|
|
6013
|
+
/** Standard INSERT orchestration, including VALUES/SELECT sources and upsert hook. */
|
|
6014
|
+
declare class StandardInsertCompiler {
|
|
6015
|
+
private readonly services;
|
|
6016
|
+
private readonly sources;
|
|
6017
|
+
constructor(services: StandardSqlCompilerServices, sources: StandardSqlSourceCompiler);
|
|
6018
|
+
compile(ast: InsertQueryNode, ctx: CompilerContext): string;
|
|
6019
|
+
compileSource(source: InsertSourceNode, ctx: CompilerContext): string;
|
|
6020
|
+
compileColumnList(columns: ColumnNode[]): string;
|
|
6021
|
+
ensureConflictColumns(clause: UpsertClause, message: string): void;
|
|
6022
|
+
}
|
|
6023
|
+
|
|
6024
|
+
/** Standard UPDATE orchestration, independent from concrete dialect classes. */
|
|
6025
|
+
declare class StandardUpdateCompiler {
|
|
6026
|
+
private readonly services;
|
|
6027
|
+
private readonly sources;
|
|
6028
|
+
constructor(services: StandardSqlCompilerServices, sources: StandardSqlSourceCompiler);
|
|
6029
|
+
compile(ast: UpdateQueryNode, ctx: CompilerContext): string;
|
|
6030
|
+
compileAssignments(assignments: {
|
|
6031
|
+
column: ColumnNode;
|
|
6032
|
+
value: OperandNode;
|
|
6033
|
+
}[], table: TableNode, ctx: CompilerContext): string;
|
|
6034
|
+
private compileFromClause;
|
|
6035
|
+
}
|
|
6036
|
+
|
|
6037
|
+
/** Standard DELETE orchestration, independent from concrete dialect classes. */
|
|
6038
|
+
declare class StandardDeleteCompiler {
|
|
6039
|
+
private readonly services;
|
|
6040
|
+
private readonly sources;
|
|
6041
|
+
constructor(services: StandardSqlCompilerServices, sources: StandardSqlSourceCompiler);
|
|
6042
|
+
compile(ast: DeleteQueryNode, ctx: CompilerContext): string;
|
|
6043
|
+
private compileUsingClause;
|
|
6044
|
+
}
|
|
6045
|
+
|
|
6011
6046
|
/**
|
|
6012
6047
|
* Strategy interface for handling RETURNING clauses in DML statements (INSERT, UPDATE, DELETE).
|
|
6013
6048
|
* Different SQL dialects have varying levels of support for RETURNING clauses.
|
|
@@ -6031,51 +6066,49 @@ interface ReturningStrategy {
|
|
|
6031
6066
|
}
|
|
6032
6067
|
|
|
6033
6068
|
/**
|
|
6034
|
-
*
|
|
6035
|
-
*
|
|
6036
|
-
*
|
|
6069
|
+
* Thin assembly base for dialects that use MetalORM's standard SQL compilers.
|
|
6070
|
+
*
|
|
6071
|
+
* SELECT/INSERT/UPDATE/DELETE orchestration lives in independent compiler
|
|
6072
|
+
* objects. This class only wires dialect-specific syntax hooks and strategies
|
|
6073
|
+
* into those components.
|
|
6037
6074
|
*/
|
|
6038
|
-
declare abstract class SqlDialectBase extends
|
|
6075
|
+
declare abstract class SqlDialectBase extends DialectBase {
|
|
6039
6076
|
abstract quoteIdentifier(id: string): string;
|
|
6040
6077
|
protected paginationStrategy: PaginationStrategy;
|
|
6041
6078
|
protected returningStrategy: ReturningStrategy;
|
|
6079
|
+
private readonly sourceCompiler;
|
|
6080
|
+
private readonly selectCompiler;
|
|
6081
|
+
private readonly insertCompiler;
|
|
6082
|
+
private readonly updateCompiler;
|
|
6083
|
+
private readonly deleteCompiler;
|
|
6084
|
+
protected constructor(functionStrategy?: FunctionStrategy, tableFunctionStrategy?: TableFunctionStrategy);
|
|
6042
6085
|
protected compileSelectAst(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
6043
|
-
private compileSelectWithSetOps;
|
|
6044
6086
|
protected compileInsertAst(ast: InsertQueryNode, ctx: CompilerContext): string;
|
|
6087
|
+
protected compileUpdateAst(ast: UpdateQueryNode, ctx: CompilerContext): string;
|
|
6088
|
+
protected compileDeleteAst(ast: DeleteQueryNode, ctx: CompilerContext): string;
|
|
6045
6089
|
protected compileUpsertClause(ast: InsertQueryNode, _ctx: CompilerContext): string;
|
|
6046
6090
|
protected compileReturning(returning: ColumnNode[] | undefined, ctx: CompilerContext): string;
|
|
6047
|
-
protected compileInsertSource(source: InsertSourceNode, ctx: CompilerContext): string;
|
|
6048
|
-
protected compileInsertColumnList(columns: ColumnNode[]): string;
|
|
6049
6091
|
protected ensureConflictColumns(clause: UpsertClause, message: string): void;
|
|
6050
|
-
private compileSelectCore;
|
|
6051
|
-
protected compileUpdateAst(ast: UpdateQueryNode, ctx: CompilerContext): string;
|
|
6052
6092
|
protected compileUpdateAssignments(assignments: {
|
|
6053
6093
|
column: ColumnNode;
|
|
6054
6094
|
value: OperandNode;
|
|
6055
6095
|
}[], table: TableNode, ctx: CompilerContext): string;
|
|
6056
6096
|
protected compileSetTarget(column: ColumnNode, table: TableNode): string;
|
|
6057
6097
|
protected compileQualifiedColumn(column: ColumnNode, table: TableNode): string;
|
|
6058
|
-
protected compileDeleteAst(ast: DeleteQueryNode, ctx: CompilerContext): string;
|
|
6059
6098
|
protected formatReturningColumns(returning: ColumnNode[]): string;
|
|
6060
|
-
protected
|
|
6061
|
-
protected compileSelectColumns(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
6062
|
-
protected compileFrom(ast: SelectQueryNode['from'], ctx?: CompilerContext): string;
|
|
6099
|
+
protected compileFrom(source: TableSourceNode, ctx?: CompilerContext): string;
|
|
6063
6100
|
protected compileFunctionTable(fn: FunctionTableNode, ctx?: CompilerContext): string;
|
|
6064
6101
|
protected compileDerivedTable(table: DerivedTableNode, ctx?: CompilerContext): string;
|
|
6065
6102
|
protected compileTableSource(table: TableSourceNode): string;
|
|
6066
6103
|
protected compileTableName(table: {
|
|
6067
6104
|
name: string;
|
|
6068
6105
|
schema?: string;
|
|
6069
|
-
alias?: string;
|
|
6070
6106
|
}): string;
|
|
6071
6107
|
protected compileTableReference(table: {
|
|
6072
6108
|
name: string;
|
|
6073
6109
|
schema?: string;
|
|
6074
6110
|
alias?: string;
|
|
6075
6111
|
}): string;
|
|
6076
|
-
private compileUpdateFromClause;
|
|
6077
|
-
private compileDeleteUsingClause;
|
|
6078
|
-
protected compileHaving(ast: SelectQueryNode, ctx: CompilerContext): string;
|
|
6079
6112
|
protected stripTrailingSemicolon(sql: string): string;
|
|
6080
6113
|
protected wrapSetOperand(sql: string): string;
|
|
6081
6114
|
protected renderOrderByNulls(order: OrderByNode): string | undefined;
|
|
@@ -6085,7 +6118,7 @@ declare abstract class SqlDialectBase extends Dialect {
|
|
|
6085
6118
|
/**
|
|
6086
6119
|
* MySQL dialect implementation
|
|
6087
6120
|
*/
|
|
6088
|
-
declare class MySqlDialect extends SqlDialectBase {
|
|
6121
|
+
declare class MySqlDialect extends SqlDialectBase implements ProcedureCompiler {
|
|
6089
6122
|
protected readonly dialect = "mysql";
|
|
6090
6123
|
/**
|
|
6091
6124
|
* Creates a new MySqlDialect instance
|
|
@@ -6110,7 +6143,7 @@ declare class MySqlDialect extends SqlDialectBase {
|
|
|
6110
6143
|
/**
|
|
6111
6144
|
* Microsoft SQL Server dialect implementation
|
|
6112
6145
|
*/
|
|
6113
|
-
declare class SqlServerDialect extends SqlDialectBase {
|
|
6146
|
+
declare class SqlServerDialect extends SqlDialectBase implements ProcedureCompiler {
|
|
6114
6147
|
protected readonly dialect = "mssql";
|
|
6115
6148
|
/**
|
|
6116
6149
|
* Creates a new SqlServerDialect instance
|
|
@@ -6183,13 +6216,12 @@ declare class SqliteDialect extends SqlDialectBase {
|
|
|
6183
6216
|
protected formatReturningColumns(returning: ColumnNode[]): string;
|
|
6184
6217
|
protected compileUpsertClause(ast: InsertQueryNode, ctx: CompilerContext): string;
|
|
6185
6218
|
supportsDmlReturningClause(): boolean;
|
|
6186
|
-
compileProcedureCall(_ast: ProcedureCallNode): CompiledProcedureCall;
|
|
6187
6219
|
}
|
|
6188
6220
|
|
|
6189
6221
|
/**
|
|
6190
6222
|
* PostgreSQL dialect implementation
|
|
6191
6223
|
*/
|
|
6192
|
-
declare class PostgresDialect extends SqlDialectBase {
|
|
6224
|
+
declare class PostgresDialect extends SqlDialectBase implements ProcedureCompiler {
|
|
6193
6225
|
protected readonly dialect = "postgres";
|
|
6194
6226
|
/**
|
|
6195
6227
|
* Creates a new PostgresDialect instance
|
|
@@ -10521,4 +10553,4 @@ declare class BulkUpsertExecutor extends BulkBaseExecutor<UpsertExecutorOptions>
|
|
|
10521
10553
|
}
|
|
10522
10554
|
declare function bulkUpsert<TTable extends TableDef>(session: OrmSession, table: TTable, rows: InsertRow[], options?: BulkUpsertOptions): Promise<BulkResult>;
|
|
10523
10555
|
|
|
10524
|
-
export { type AliasRefNode, Alphanumeric, type AnyDomainEvent, type ApiRouteDefinition, type ApplyFilterOptions, type ArithmeticExpressionNode, type TableRef as AstTableRef, AsyncLocalStorage, type AutoCorrectionResult, type AutoTransformResult, type AutoTransformableValidator, BelongsTo, BelongsToMany, type BelongsToManyOptions, type BelongsToManyRelation, type BelongsToOptions, type BelongsToReference, type BelongsToReferenceApi, type BelongsToRelation, type BetterSqlite3ClientLike, type BetterSqlite3Statement, type BetweenExpressionNode, BigIntTypeStrategy, type BinaryExpressionNode, BinaryTypeStrategy, type BitwiseExpressionNode, type BooleanFilter, BooleanTypeStrategy, type BulkBaseOptions, type BulkConcurrency, BulkDeleteExecutor, type BulkDeleteOptions, BulkInsertExecutor, type BulkInsertOptions, type BulkResult, BulkUpdateExecutor, type BulkUpdateOptions, BulkUpsertExecutor, type BulkUpsertOptions, CEP, CNPJ, CPF, type CacheCapabilities, type CacheInvalidator, type CacheOptions, type CacheProvider, type CacheReader, type CacheState, type CacheStrategy, type CacheWriter, type CallProcedureOptions, Capitalize, type CascadeMode, type CaseExpressionNode, type CastExpressionNode, type CheckConstraint, type ChunkCompleteInfo, type ChunkOutcome, type CollateExpressionNode, Column, type ColumnDef, type ColumnDiff, type ColumnInput, type ColumnNode, type ColumnOptions, type ColumnRef, type ColumnToTs, type ColumnType, type ComponentOptions, type ComponentReference, type CompositeTransformer, ConflictBuilder, ConstructorMaterializationStrategy, type ValidationResult as CountryValidationResult, type CountryValidator, type CountryValidatorFactory, type CreateDto, type CreateTediousClientOptions, type CursorPageInfo, type CursorPageOptions, type CursorPageResult, DEFAULT_TREE_CONFIG, type DatabaseCheck, type DatabaseColumn, type DatabaseIndex, type DatabaseSchema, type DatabaseTable, type DatabaseView, type DateFilter, DateTimeTypeStrategy, type DbExecutor, type DbExecutorFactory, DecimalTypeStrategy, type DecoratedEntityInstance, DefaultBelongsToReference, DefaultCacheStrategy, DefaultEntityMaterializer, DefaultHasManyCollection, DefaultManyToManyCollection, DefaultMorphManyCollection, DefaultMorphOneReference, DefaultMorphToReference, DefaultTypeStrategy, type DefaultValue, DeleteQueryBuilder, type DialectName, type DomainEvent, DomainEventBus, type DomainEventHandler, type Dto, type Duration, Email, Entity, type EntityContext, type EntityInstance, type EntityMaterializationStrategy, type EntityMaterializer, type EntityOptions, type PrimaryKey$1 as EntityPrimaryKey, EntityStatus, type ExecuteFilteredPagedOptions, type ExecutionContext, type ExecutionPayload, type ExistsExpressionNode, type ExpressionNode, type ExpressionVisitor, type FieldFilter, type FilterOperator, type FilterValue, type FindChildrenOptions, type FindPathOptions, type ForeignKeyReference, type FunctionNode, type GroupConcatOptions, type HasDomainEvents, HasMany, type HasManyCollection, type HasManyOptions, type HasManyRelation, HasOne, type HasOneOptions, type HasOneReference, type HasOneReferenceApi, type HasOneRelation, type HydrationContext, type HydrationMetadata, type HydrationPivotPlan, type HydrationPlan, type HydrationRelationPlan, type InExpressionNode, type InExpressionRight, type IndexColumn, type IndexDef, type InferRow, type InitialHandlers, InsertQueryBuilder, type InsertRow, IntegerTypeStrategy, InterceptorPipeline, type IntrospectOptions, type InvalidationStrategy, type IsDistinctExpressionNode, type JsonArray, type JsonObject, type JsonPathNode, type JsonValue, type Jsonify, type JsonifyScalar, KeyvCacheAdapter, Length, type LiteralNode, type LiteralValue, type LogicalExpressionNode, Lower, type ManyToManyCollection, MemoryCacheAdapter, MorphMany, type MorphManyOptions, type MorphManyRelation, MorphOne, type MorphOneOptions, type MorphOneRelation, MorphTo, type MorphToOptions, type MorphToRelation, type MoveOptions, type MssqlClientLike, MySqlDialect, type MysqlClientLike, type NestedDtoOptions, type NestedSetBounds, type NestedSetRow, NestedSetStrategy, type NodeWithPk, type NotExpressionNode, type NullExpressionNode, type NumberFilter, type OpenApiComponent, type OpenApiDialect, type OpenApiDocument, type OpenApiDocumentInfo, type OpenApiDocumentOptions, type OpenApiOperation, type OpenApiParameter, type OpenApiParameterObject, type OpenApiResponseObject, type OpenApiSchema, type OpenApiType, type OperandNode, type OperandVisitor, Orm, type OrmCacheOptions, type OrmDomainEvent, type OrmInterceptor, type OrmOptions, OrmSession, type OrmSessionOptions, type PagedResponse, type PaginatedResult, type PaginationParams, type PatchGraphInputPayload, Pattern, Pool, type PoolAdapter, type PoolLease, type PoolOptions, type PooledConnectionAdapter, type PostgresClientLike, PostgresDialect, PrimaryKey, type Primitive, ProcedureCallBuilder, type ProcedureCallNode, type ProcedureDirection, type ProcedureExecutionResult, type ProcedureOutOptions, type ProcedureParamNode, type ProcedureRefNode, type PropertySanitizer, type PropertyTransformer, type PropertyValidator, PrototypeMaterializationStrategy, QueryCacheManager, type QueryContext, type QueryInterceptor, type QueryLogEntry, type QueryLogger, type QueryResult, type RawDefaultValue, type RecoverResult, RedisCacheAdapter, type ReferentialAction, type RelationChange, type RelationChangeEntry, type RelationDef, type RelationFilter, type RelationKey$1 as RelationKey, RelationKinds, type RelationMap, type RelationTargetTable, type RelationType, type RenderColumnOptions, STANDARD_COLUMN_TYPES, type SaveGraphInputPayload, type SaveGraphInputScalar, type SaveGraphJsonScalar, type SaveGraphSessionOptions, type ScalarSubqueryNode, type SchemaChange, type SchemaChangeKind, type SchemaDiffOptions, type SchemaGenerateResult, type SchemaIntrospector, type SchemaPlan, SelectQueryBuilder, type SelectQueryInput, type SelectableKeys, type SimpleQueryRunner, type SimpleWhereInput, type Simplify, SqlServerDialect, type SqliteClientLike, SqliteDialect, type StandardColumnType, type StringFilter, StringTypeStrategy, type SynchronizeOptions, type TableDef, type TableHookResolver, type TableHooks, type TableOptions, type TableRef$1 as TableRef, TagIndex, type TargetType, type TediousColumn, type TediousConnectionLike, type TediousModule, type TediousRequest, type TediousRequestCtor, type TediousTypes, type ThreadedNode, Title, type ToJsonOptions, type TrackedEntity, type TransformContext, type TransformerConfig, type TransformerMetadata, Tree, TreeChildren, type TreeColumns, type TreeConfig, type TreeDecoratorOptions, type TreeInsertData, type TreeListEntry, type TreeListOptions, type TreeListSchemaOptions, TreeManager, type TreeManagerOptions, type TreeMetadata, type TreeMoveData, type TreeNode, type TreeNodeResult, type TreeNodeResultSchemaOptions, type TreeNodeSchemaOptions, TreeParent, type TreeQuery, type TreeScope, type TreeValidationResult, Trim, TypeMappingService, type TypeMappingStrategy, TypeScriptGenerator, type TypedExpression, type TypedLike, type UpdateDto, UpdateQueryBuilder, type UpdateRow, Upper, UuidTypeStrategy, type ValidationOptions, type ValidationResult$1 as ValidationResult, type ValidatorFactoryOptions, type ValueOperandInput, type VectorInput, type VectorMetric, type WhereInput, type WindowFunctionNode, type WithRelations, abs, acos, add, addDomainEvent, addEntityRelation, addRelation, age, aliasRef, and, applyFilter, applyNullability, arrayAppend, asType, ascii, asin, atan, atan2, avg, belongsTo, belongsToMany, between, bitAnd, bitLength, bitOr, bitXor, bootstrapEntities, buildFilterExpression, buildScopeConditions, bulkDelete, bulkDeleteWhere, bulkInsert, bulkUpdate, bulkUpdateWhere, bulkUpsert, calculateRowDepths, calculateTotalPages, callProcedure, canonicalizeSchema, caseWhen, cast, cbrt, ceil, ceiling, char, charLength, chr, clearExpressionDispatchers, clearOperandDispatchers, coalesce, col, collate, columnOperand, columnToFilterSchema, columnToOpenApiSchema, columnTypeToOpenApiFormat, columnTypeToOpenApiType, computePaginationMetadata, computeSchemaHash, concat, concatWs, correlateBy, cos, cosineDistance, cot, count, countAll, createApiComponentsSection, createBetterSqlite3Executor, createDeterministicNamingState, createDtoToOpenApiSchema, createEntityFromRow, createEntityProxy, createExecutorFromQueryRunner, createMssqlExecutor, createMysqlExecutor, createPooledExecutorFactory, createPostgresExecutor, createQueryLoggingExecutor, createRef, createSqliteExecutor, createTediousExecutor, createTediousMssqlClient, createTreeManager, currentDate, currentTime, dateAdd, dateDiff, dateFormat, dateSub, dateTrunc, day, dayOfWeek, deepCloneSchema, defineTable, degrees, deleteFrom, denseRank, diffSchema, div, dotProduct, dtoToOpenApiSchema, endOfMonth, entityRef, entityRefs, eq, esel, euclideanDistance, exclude, executeFilteredPaged, executeHydrated, executeHydratedPlain, executeHydratedPlainWithContexts, executeHydratedWithContexts, executeProcedureAst, executeSchemaSql, executeSchemaSqlFor, exists, exp, extract, extractReusableSchemas, extractScopeValues, firstValue, floor, formatDuration, formatTreeList, fromUnixTime, generateComponentSchemas, generateCreateTableSql, generateOpenApiDocument, generateRelationComponents, generateSchemaSql, generateSchemaSqlFor, generateTreeComponents, getColumn, getColumnMap, getColumnType, getDateKind, getDecoratorMetadata, getDeterministicComponentName, getOpenApiVersionForDialect, getRegisteredValidators, getSchemaIntrospector, getTableDefFromEntity, getTreeBounds, getTreeColumns, getTreeConfig, getTreeMetadata, getTreeParentId, greatest, groupConcat, gt, gte, hasMany, hasNextPage as hasNextPageMeta, hasOne, hasPrevPage as hasPrevPageMeta, hasTreeBehavior, hasValidator, hour, hydrateRows, ifNull, inList, inSubquery, initcap, innerProduct, insertInto, instr, introspectSchema, isCaseExpressionNode, isCastExpressionNode, isCollateExpressionNode, isComponentReference, isDistinctFrom, isExpressionSelectionNode, isFunctionNode, isMorphRelation, isNotDistinctFrom, isNotNull, isNull, isNullableColumn, isOperandNode, isSingleTargetRelation, isTableDef, isTreeConfig, isValidDuration, isValueOperandInput, isWindowFunctionNode, jsonArrayAgg, jsonContains, jsonLength, jsonPath, jsonSet, jsonify, l1Distance, l2Distance, lag, lastValue, lead, least, left, length, like, ln, loadBelongsToManyRelation, loadBelongsToRelation, loadHasManyRelation, loadHasOneRelation, loadMorphManyRelation, loadMorphOneRelation, loadMorphToRelation, localTime, localTimestamp, locate, log, log10, log2, logBase, lower, lpad, lt, lte, ltrim, manhattanDistance, mapFields, materializeAs, max, md5, mergeSchemas, min, minute, mod, month, morphMany, morphOne, morphTo, mul, neq, nestedDtoToOpenApiSchema, nestedWhereInputToOpenApiSchema, normalizeColumnType, not, notBetween, notExists, notInList, notInSubquery, notLike, now, ntile, nullif, octetLength, or, outerRef, pagedResponseToOpenApiSchema, paginationParamsSchema, parameterToRef, parseDuration, payloadResultSets, pi, pick, position, pow, power, quarter, radians, rand, random, rank, registerExpressionDispatcher, registerOperandDispatcher, registerSchemaIntrospector, registerValidator, relationFilterToOpenApiSchema, relationLoaderCache, renderColumnDefinition, renderTypeWithArgs, repeat, replace, replaceWithRefs, resolveTreeConfig, resolveValidator, responseToRef, reverse, right, round, rowNumber, rowsToQueryResult, rpad, rtrim, schemaToJson, schemaToRef, second, sel, selectFrom, selectFromEntity, setRelations, setTreeBounds, setTreeMetadata, setTreeParentId, sha1, sha2, shiftLeft, shiftRight, sign, sin, space, sqrt, stddev, sub, substr, sum, syncTreeEntityMetadata, synchronizeSchema, tableRef, tan, threadResults, threadedNodeToOpenApiSchema, toColumnRef, toExecutionPayload, toPagedResponse, toPagedResponseBuilder, toPaginationParams, toResponse, toResponseBuilder, toTableRef, treeEntityRegistry, treeListEntryToOpenApiSchema, treeNodeResultToOpenApiSchema, treeNodeToOpenApiSchema, treeQuery, trim, trunc, truncate, typeMappingService, unixTimestamp, update, updateDtoToOpenApiSchema, updateDtoWithRelationsToOpenApiSchema, upper, utcNow, validateTreeTable, valueToOperand, variance, vectorDistance, vectorMatch, visitExpression, visitOperand, weekOfYear, whereInputToOpenApiSchema, whereInputWithRelationsToOpenApiSchema, windowFunction, withDefaults, withDefaultsBuilder, year };
|
|
10556
|
+
export { type AliasRefNode, Alphanumeric, type AnyDomainEvent, type ApiRouteDefinition, type ApplyFilterOptions, type ArithmeticExpressionNode, type TableRef as AstTableRef, AsyncLocalStorage, type AutoCorrectionResult, type AutoTransformResult, type AutoTransformableValidator, BelongsTo, BelongsToMany, type BelongsToManyOptions, type BelongsToManyRelation, type BelongsToOptions, type BelongsToReference, type BelongsToReferenceApi, type BelongsToRelation, type BetterSqlite3ClientLike, type BetterSqlite3Statement, type BetweenExpressionNode, BigIntTypeStrategy, type BinaryExpressionNode, BinaryTypeStrategy, type BitwiseExpressionNode, type BooleanFilter, BooleanTypeStrategy, type BulkBaseOptions, type BulkConcurrency, BulkDeleteExecutor, type BulkDeleteOptions, BulkInsertExecutor, type BulkInsertOptions, type BulkResult, BulkUpdateExecutor, type BulkUpdateOptions, BulkUpsertExecutor, type BulkUpsertOptions, CEP, CNPJ, CPF, type CacheCapabilities, type CacheInvalidator, type CacheOptions, type CacheProvider, type CacheReader, type CacheState, type CacheStrategy, type CacheWriter, type CallProcedureOptions, Capitalize, type CascadeMode, type CaseExpressionNode, type CastExpressionNode, type CheckConstraint, type ChunkCompleteInfo, type ChunkOutcome, type CollateExpressionNode, Column, type ColumnDef, type ColumnDiff, type ColumnInput, type ColumnNode, type ColumnOptions, type ColumnRef, type ColumnToTs, type ColumnType, type CompiledProcedureCall, type CompiledQuery, type CompilerContext, type ComponentOptions, type ComponentReference, type CompositeTransformer, ConflictBuilder, ConstructorMaterializationStrategy, type ValidationResult as CountryValidationResult, type CountryValidator, type CountryValidatorFactory, type CreateDto, type CreateTediousClientOptions, type CursorPageInfo, type CursorPageOptions, type CursorPageResult, DEFAULT_TREE_CONFIG, type DatabaseCheck, type DatabaseColumn, type DatabaseIndex, type DatabaseSchema, type DatabaseTable, type DatabaseView, type DateFilter, DateTimeTypeStrategy, type DbExecutor, type DbExecutorFactory, DecimalTypeStrategy, type DecoratedEntityInstance, DefaultBelongsToReference, DefaultCacheStrategy, DefaultEntityMaterializer, DefaultHasManyCollection, DefaultManyToManyCollection, DefaultMorphManyCollection, DefaultMorphOneReference, DefaultMorphToReference, DefaultTypeStrategy, type DefaultValue, type DeleteCompiler, DeleteQueryBuilder, type Dialect, DialectBase, DialectFactory, type DialectKey, type DialectName, type DomainEvent, DomainEventBus, type DomainEventHandler, type Dto, type Duration, Email, Entity, type EntityContext, type EntityInstance, type EntityMaterializationStrategy, type EntityMaterializer, type EntityOptions, type PrimaryKey$1 as EntityPrimaryKey, EntityStatus, type ExecuteFilteredPagedOptions, type ExecutionContext, type ExecutionPayload, type ExistsExpressionNode, type ExpressionNode, type ExpressionVisitor, type FieldFilter, type FilterOperator, type FilterValue, type FindChildrenOptions, type FindPathOptions, type ForeignKeyReference, type FunctionNode, type GroupConcatOptions, type HasDomainEvents, HasMany, type HasManyCollection, type HasManyOptions, type HasManyRelation, HasOne, type HasOneOptions, type HasOneReference, type HasOneReferenceApi, type HasOneRelation, type HydrationContext, type HydrationMetadata, type HydrationPivotPlan, type HydrationPlan, type HydrationRelationPlan, type InExpressionNode, type InExpressionRight, type IndexColumn, type IndexDef, type InferRow, type InitialHandlers, type InsertCompiler, InsertQueryBuilder, type InsertRow, IntegerTypeStrategy, InterceptorPipeline, type IntrospectOptions, type InvalidationStrategy, type IsDistinctExpressionNode, type JsonArray, type JsonObject, type JsonPathNode, type JsonValue, type Jsonify, type JsonifyScalar, KeyvCacheAdapter, Length, type LiteralNode, type LiteralValue, type LogicalExpressionNode, Lower, type ManyToManyCollection, MemoryCacheAdapter, MorphMany, type MorphManyOptions, type MorphManyRelation, MorphOne, type MorphOneOptions, type MorphOneRelation, MorphTo, type MorphToOptions, type MorphToRelation, type MoveOptions, type MssqlClientLike, MySqlDialect, type MysqlClientLike, type NestedDtoOptions, type NestedSetBounds, type NestedSetRow, NestedSetStrategy, type NodeWithPk, type NotExpressionNode, type NullExpressionNode, type NumberFilter, type OpenApiComponent, type OpenApiDialect, type OpenApiDocument, type OpenApiDocumentInfo, type OpenApiDocumentOptions, type OpenApiOperation, type OpenApiParameter, type OpenApiParameterObject, type OpenApiResponseObject, type OpenApiSchema, type OpenApiType, type OperandNode, type OperandVisitor, Orm, type OrmCacheOptions, type OrmDomainEvent, type OrmInterceptor, type OrmOptions, OrmSession, type OrmSessionOptions, type PagedResponse, type PaginatedResult, type PaginationParams, type PatchGraphInputPayload, Pattern, Pool, type PoolAdapter, type PoolLease, type PoolOptions, type PooledConnectionAdapter, type PostgresClientLike, PostgresDialect, PrimaryKey, type Primitive, ProcedureCallBuilder, type ProcedureCallNode, type ProcedureCompiler, type ProcedureDirection, type ProcedureExecutionResult, type ProcedureOutOptions, type ProcedureParamNode, type ProcedureRefNode, type PropertySanitizer, type PropertyTransformer, type PropertyValidator, PrototypeMaterializationStrategy, QueryCacheManager, type QueryContext, type QueryInterceptor, type QueryLogEntry, type QueryLogger, type QueryResult, type RawDefaultValue, type RecoverResult, RedisCacheAdapter, type ReferentialAction, type RelationChange, type RelationChangeEntry, type RelationDef, type RelationFilter, type RelationKey$1 as RelationKey, RelationKinds, type RelationMap, type RelationTargetTable, type RelationType, type RenderColumnOptions, STANDARD_COLUMN_TYPES, type SaveGraphInputPayload, type SaveGraphInputScalar, type SaveGraphJsonScalar, type SaveGraphSessionOptions, type ScalarSubqueryNode, type SchemaChange, type SchemaChangeKind, type SchemaDiffOptions, type SchemaGenerateResult, type SchemaIntrospector, type SchemaPlan, type SelectCompiler, SelectQueryBuilder, type SelectQueryInput, type SelectableKeys, type SimpleQueryRunner, type SimpleWhereInput, type Simplify, SqlServerDialect, type SqliteClientLike, SqliteDialect, type StandardColumnType, StandardDeleteCompiler, StandardInsertCompiler, StandardSelectCompiler, type StandardSqlCompilerServices, StandardSqlSourceCompiler, StandardUpdateCompiler, type StringFilter, StringTypeStrategy, type SynchronizeOptions, type TableDef, type TableHookResolver, type TableHooks, type TableOptions, type TableRef$1 as TableRef, TagIndex, type TargetType, type TediousColumn, type TediousConnectionLike, type TediousModule, type TediousRequest, type TediousRequestCtor, type TediousTypes, type ThreadedNode, Title, type ToJsonOptions, type TrackedEntity, type TransformContext, type TransformerConfig, type TransformerMetadata, Tree, TreeChildren, type TreeColumns, type TreeConfig, type TreeDecoratorOptions, type TreeInsertData, type TreeListEntry, type TreeListOptions, type TreeListSchemaOptions, TreeManager, type TreeManagerOptions, type TreeMetadata, type TreeMoveData, type TreeNode, type TreeNodeResult, type TreeNodeResultSchemaOptions, type TreeNodeSchemaOptions, TreeParent, type TreeQuery, type TreeScope, type TreeValidationResult, Trim, TypeMappingService, type TypeMappingStrategy, TypeScriptGenerator, type TypedExpression, type TypedLike, type UpdateCompiler, type UpdateDto, UpdateQueryBuilder, type UpdateRow, Upper, UuidTypeStrategy, type ValidationOptions, type ValidationResult$1 as ValidationResult, type ValidatorFactoryOptions, type ValueOperandInput, type VectorInput, type VectorMetric, type WhereInput, type WindowFunctionNode, type WithRelations, abs, acos, add, addDomainEvent, addEntityRelation, addRelation, age, aliasRef, and, applyFilter, applyNullability, arrayAppend, asType, ascii, asin, atan, atan2, avg, belongsTo, belongsToMany, between, bitAnd, bitLength, bitOr, bitXor, bootstrapEntities, buildFilterExpression, buildScopeConditions, bulkDelete, bulkDeleteWhere, bulkInsert, bulkUpdate, bulkUpdateWhere, bulkUpsert, calculateRowDepths, calculateTotalPages, callProcedure, canonicalizeSchema, caseWhen, cast, cbrt, ceil, ceiling, char, charLength, chr, clearExpressionDispatchers, clearOperandDispatchers, coalesce, col, collate, columnOperand, columnToFilterSchema, columnToOpenApiSchema, columnTypeToOpenApiFormat, columnTypeToOpenApiType, computePaginationMetadata, computeSchemaHash, concat, concatWs, correlateBy, cos, cosineDistance, cot, count, countAll, createApiComponentsSection, createBetterSqlite3Executor, createDeterministicNamingState, createDtoToOpenApiSchema, createEntityFromRow, createEntityProxy, createExecutorFromQueryRunner, createMssqlExecutor, createMysqlExecutor, createPooledExecutorFactory, createPostgresExecutor, createQueryLoggingExecutor, createRef, createSqliteExecutor, createTediousExecutor, createTediousMssqlClient, createTreeManager, currentDate, currentTime, dateAdd, dateDiff, dateFormat, dateSub, dateTrunc, day, dayOfWeek, deepCloneSchema, defineTable, degrees, deleteFrom, denseRank, diffSchema, div, dotProduct, dtoToOpenApiSchema, endOfMonth, entityRef, entityRefs, eq, esel, euclideanDistance, exclude, executeFilteredPaged, executeHydrated, executeHydratedPlain, executeHydratedPlainWithContexts, executeHydratedWithContexts, executeProcedureAst, executeSchemaSql, executeSchemaSqlFor, exists, exp, extract, extractReusableSchemas, extractScopeValues, firstValue, floor, formatDuration, formatTreeList, fromUnixTime, generateComponentSchemas, generateCreateTableSql, generateOpenApiDocument, generateRelationComponents, generateSchemaSql, generateSchemaSqlFor, generateTreeComponents, getColumn, getColumnMap, getColumnType, getDateKind, getDecoratorMetadata, getDeterministicComponentName, getOpenApiVersionForDialect, getRegisteredValidators, getSchemaIntrospector, getTableDefFromEntity, getTreeBounds, getTreeColumns, getTreeConfig, getTreeMetadata, getTreeParentId, greatest, groupConcat, gt, gte, hasMany, hasNextPage as hasNextPageMeta, hasOne, hasPrevPage as hasPrevPageMeta, hasTreeBehavior, hasValidator, hour, hydrateRows, ifNull, inList, inSubquery, initcap, innerProduct, insertInto, instr, introspectSchema, isCaseExpressionNode, isCastExpressionNode, isCollateExpressionNode, isComponentReference, isDistinctFrom, isExpressionSelectionNode, isFunctionNode, isMorphRelation, isNotDistinctFrom, isNotNull, isNull, isNullableColumn, isOperandNode, isProcedureCompiler, isSingleTargetRelation, isTableDef, isTreeConfig, isValidDuration, isValueOperandInput, isWindowFunctionNode, jsonArrayAgg, jsonContains, jsonLength, jsonPath, jsonSet, jsonify, l1Distance, l2Distance, lag, lastValue, lead, least, left, length, like, ln, loadBelongsToManyRelation, loadBelongsToRelation, loadHasManyRelation, loadHasOneRelation, loadMorphManyRelation, loadMorphOneRelation, loadMorphToRelation, localTime, localTimestamp, locate, log, log10, log2, logBase, lower, lpad, lt, lte, ltrim, manhattanDistance, mapFields, materializeAs, max, md5, mergeSchemas, min, minute, mod, month, morphMany, morphOne, morphTo, mul, neq, nestedDtoToOpenApiSchema, nestedWhereInputToOpenApiSchema, normalizeColumnType, not, notBetween, notExists, notInList, notInSubquery, notLike, now, ntile, nullif, octetLength, or, outerRef, pagedResponseToOpenApiSchema, paginationParamsSchema, parameterToRef, parseDuration, payloadResultSets, pi, pick, position, pow, power, quarter, radians, rand, random, rank, registerExpressionDispatcher, registerOperandDispatcher, registerSchemaIntrospector, registerValidator, relationFilterToOpenApiSchema, relationLoaderCache, renderColumnDefinition, renderTypeWithArgs, repeat, replace, replaceWithRefs, requireProcedureCompiler, resolveDialectInput, resolveTreeConfig, resolveValidator, responseToRef, reverse, right, round, rowNumber, rowsToQueryResult, rpad, rtrim, schemaToJson, schemaToRef, second, sel, selectFrom, selectFromEntity, setRelations, setTreeBounds, setTreeMetadata, setTreeParentId, sha1, sha2, shiftLeft, shiftRight, sign, sin, space, sqrt, stddev, sub, substr, sum, syncTreeEntityMetadata, synchronizeSchema, tableRef, tan, threadResults, threadedNodeToOpenApiSchema, toColumnRef, toExecutionPayload, toPagedResponse, toPagedResponseBuilder, toPaginationParams, toResponse, toResponseBuilder, toTableRef, treeEntityRegistry, treeListEntryToOpenApiSchema, treeNodeResultToOpenApiSchema, treeNodeToOpenApiSchema, treeQuery, trim, trunc, truncate, typeMappingService, unixTimestamp, update, updateDtoToOpenApiSchema, updateDtoWithRelationsToOpenApiSchema, upper, utcNow, validateTreeTable, valueToOperand, variance, vectorDistance, vectorMatch, visitExpression, visitOperand, weekOfYear, whereInputToOpenApiSchema, whereInputWithRelationsToOpenApiSchema, windowFunction, withDefaults, withDefaultsBuilder, year };
|