Defined in: packages/db/src/query/builder/types.ts:44
Context - The central state container for query builder operations
This interface tracks all the information needed to build and type-check queries:
Schema Management:
Query State:
Result Tracking:
The context evolves through the query builder chain:
baseSchema: ContextSchema;Defined in: packages/db/src/query/builder/types.ts:46
fromSourceName: string;Defined in: packages/db/src/query/builder/types.ts:52
optional fromSourceNames: readonly string[];Defined in: packages/db/src/query/builder/types.ts:54
optional hasJoins: boolean;Defined in: packages/db/src/query/builder/types.ts:58
optional hasResult: true;Defined in: packages/db/src/query/builder/types.ts:67
optional hasUnionFrom: true;Defined in: packages/db/src/query/builder/types.ts:56
optional joinTypes: Record<string, "inner" | "left" | "right" | "full" | "outer" | "cross">;Defined in: packages/db/src/query/builder/types.ts:60
optional refsSchema: ContextSchema;Defined in: packages/db/src/query/builder/types.ts:50
optional result: any;Defined in: packages/db/src/query/builder/types.ts:65
schema: ContextSchema;Defined in: packages/db/src/query/builder/types.ts:48
optional singleResult: boolean;Defined in: packages/db/src/query/builder/types.ts:69