common-table-expression overview
Added in v2.0.0
Table of contents
utils
CommonTableExpressionFactory (class)
Signature
export declare class CommonTableExpressionFactory<
Selection,
Alias,
Scope,
FlatScope
> {
private constructor(
/* @internal */
public __props: {
readonly ctes: ReadonlyArray<CTE>;
}
);
}
Added in v2.0.0
with_ (property)
Signature
with_: <NSelection extends string, NAlias extends string>(
select: (acc: {
[K in keyof Scope]: Table<
Scope[K],
never,
{ [k in K]: Scope[K] },
Scope[K]
>;
}) => AliasedSelectStatement<NSelection, NAlias, any, any>
) =>
CommonTableExpressionFactory<
Selection,
Alias,
Scope & { [key in NAlias]: NSelection },
FlatScope | NSelection
>;
Added in v2.0.0
withR (property)
Signature
withR: <NSelection extends string, NAlias extends string>(
select: (acc: {
[K in keyof Scope]: Table<
Scope[K],
never,
{ [k in K]: Scope[K] },
Scope[K]
>;
}) => AliasedSelectStatement<any, NAlias, any, any>,
columns: readonly NSelection[]
) =>
CommonTableExpressionFactory<
Selection,
Alias,
Scope & { [key in NAlias]: NSelection },
FlatScope | NSelection
>;
Added in v2.0.0
do (property)
Signature
do: <NSelection extends string, NAlias extends string, NScope extends ScopeShape, NFlatScope extends string>(_: (acc: { [K in keyof Scope]: Table<Scope[K], never, { [k in K]: Scope[K]; }, Scope[K]>; }) => SelectStatement<NSelection, NAlias, NScope, NFlatScope>) => SelectStatement<NSelection, NAlias, NScope, NFlatScope>
Added in v2.0.0