@vibeorm/sql 5.0.0 → 5.1.0

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.js.map CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../src/timestamp-identity.ts", "../src/native-enum-parameter.ts", "../src/json-list-parameter.ts", "../src/dialects/external-ownership.ts", "../src/dialects/external-dependents.ts", "../src/params.ts", "../src/sql-bindings.ts", "../src/parameter-snapshot.ts", "../src/sql-input.ts", "../src/result-decoder.ts", "../src/pg-array.ts", "../src/codecs.ts", "../src/sql-handles.ts", "../src/dialects/postgres-physical-catalog.ts", "../src/dialects/postgres-index-keys.ts", "../src/index-columns.ts", "../src/index-expressions.ts", "../src/predicate.ts", "../src/dialects/postgres-index-expressions.ts", "../src/dialects/sqlite-table-definition.ts", "../src/dialects/sqlite-index-expressions.ts", "../src/dialects/mysql-index-expressions.ts", "../src/dialects/mysql-generated-columns.ts", "../src/dialects/sqlite-generated-columns.ts", "../src/dialects/module-dependency.ts", "../src/dialects/migration-replay-coverage.ts", "../src/dialects/migration-shadow.ts", "../src/module-journal.ts", "../src/capabilities.ts", "../src/identifiers.ts", "../src/dialects/sqlite.ts", "../src/dialects/sqlite-fts.ts", "../src/dialects/sqlite-session.ts", "../src/composable.ts", "../src/query-plan.ts", "../src/exclusion.ts", "../src/ast.ts", "../src/locks.ts", "../src/json-transport.ts", "../src/dialects/postgres.ts", "../src/dialects/mysql.ts", "../src/dialects/registry.ts", "../src/key-list.ts", "../src/local-date.ts", "../src/generated-columns.ts", "../src/dialects/postgres-generated-columns.ts", "../src/row-rules.ts", "../src/dialects/postgres-row-rules.ts", "../src/dialects/sqlite-row-rules.ts", "../src/dialects/mysql-row-rules.ts", "../src/dialects/sqlite-json-equality.ts", "../src/dialects/diagnostics.ts", "../src/dialects/postgres-diagnostics.ts", "../src/dialects/postgres-rls-readiness.ts", "../src/dialects/postgres-rls.ts", "../src/render.ts", "../src/like.ts", "../src/dialects/postgres-type-identity.ts", "../src/dialects/postgres-default-identity.ts", "../src/dialects/constraint-owned-index.ts", "../src/dialects/mysql-check-probe.ts", "../src/dialects/migration-history.ts", "../src/dialects/sqlite-constraints.ts", "../src/dialects/migration-visibility.ts", "../src/dialects/migration-inventory.ts", "../src/dialects/migration-objects.ts", "../src/dialects/postgres-migration.ts"],
3
+ "sources": ["../src/timestamp-identity.ts", "../src/native-enum-parameter.ts", "../src/json-list-parameter.ts", "../src/dialects/external-ownership.ts", "../src/dialects/external-dependents.ts", "../src/params.ts", "../src/sql-bindings.ts", "../src/parameter-snapshot.ts", "../src/sql-input.ts", "../src/result-decoder.ts", "../src/pg-array.ts", "../src/codecs.ts", "../src/sql-handles.ts", "../src/dialects/postgres-physical-catalog.ts", "../src/dialects/postgres-index-keys.ts", "../src/index-columns.ts", "../src/index-expressions.ts", "../src/predicate.ts", "../src/dialects/postgres-index-expressions.ts", "../src/dialects/sqlite-table-definition.ts", "../src/dialects/sqlite-index-expressions.ts", "../src/dialects/mysql-index-expressions.ts", "../src/dialects/mysql-generated-columns.ts", "../src/dialects/sqlite-generated-columns.ts", "../src/dialects/module-dependency.ts", "../src/dialects/migration-replay-coverage.ts", "../src/dialects/migration-shadow.ts", "../src/module-journal.ts", "../src/capabilities.ts", "../src/identifiers.ts", "../src/dialects/sqlite.ts", "../src/dialects/sqlite-fts.ts", "../src/dialects/sqlite-session.ts", "../src/composable.ts", "../src/query-plan.ts", "../src/exclusion.ts", "../src/ast.ts", "../src/locks.ts", "../src/json-transport.ts", "../src/dialects/postgres.ts", "../src/dialects/mysql.ts", "../src/dialects/registry.ts", "../src/key-list.ts", "../src/local-date.ts", "../src/date-truncation.ts", "../src/generated-columns.ts", "../src/dialects/postgres-generated-columns.ts", "../src/row-rules.ts", "../src/dialects/postgres-row-rules.ts", "../src/dialects/sqlite-row-rules.ts", "../src/dialects/mysql-row-rules.ts", "../src/dialects/sqlite-json-equality.ts", "../src/dialects/diagnostics.ts", "../src/dialects/postgres-diagnostics.ts", "../src/dialects/postgres-rls-readiness.ts", "../src/dialects/postgres-rls.ts", "../src/render.ts", "../src/like.ts", "../src/dialects/postgres-type-identity.ts", "../src/dialects/postgres-default-identity.ts", "../src/dialects/constraint-owned-index.ts", "../src/dialects/mysql-check-probe.ts", "../src/dialects/migration-history.ts", "../src/dialects/sqlite-constraints.ts", "../src/dialects/migration-visibility.ts", "../src/dialects/migration-inventory.ts", "../src/dialects/migration-objects.ts", "../src/dialects/postgres-migration.ts"],
4
4
  "sourcesContent": [
5
5
  "/** Lossless database identity, never an enumerable property or a public Date subtype. */\ntype TimestampIdentity = {\n readonly milliseconds: number;\n readonly text: string;\n readonly numeric: number | undefined;\n /**\n * The exact equality key: given by the decoder, or computed on first use\n * ({@link identityKey}) — a pure function of `milliseconds` and `text`, so\n * computing it later yields the same string (A-02: most decoded Dates never\n * need it, and building it cost more than the parse itself).\n */\n key: string | undefined;\n readonly kind: \"timestamp\" | \"time\" | \"timetz\" | \"sqlite\";\n};\n\nconst identities = new WeakMap<Date, TimestampIdentity>();\n\n/** The canonical timestamp key: the instant's ISO text with the sub-millisecond digits the transport text carried. */\nfunction canonicalKey(params: { milliseconds: number; text: string }): string {\n const fraction = /\\.(\\d+)/.exec(params.text)?.[1] ?? \"\";\n const remainder = fraction.slice(3).replace(/0+$/, \"\");\n const canonical = Date.prototype.toISOString.call(new Date(params.milliseconds)).replace(/(\\.\\d{3})Z$/, `$1${remainder}Z`);\n return `date:${canonical}`;\n}\n\nfunction identityKey(identity: TimestampIdentity): string {\n if (identity.key === undefined) identity.key = canonicalKey({ milliseconds: identity.milliseconds, text: identity.text });\n return identity.key;\n}\n\n/** Retain transport text while the ordinary Date still represents the decoded value. */\nexport function rememberTimestampIdentity(params: {\n date: Date;\n text: string;\n numeric?: number;\n key?: string;\n kind?: TimestampIdentity[\"kind\"];\n}): Date {\n const { date, text } = params;\n const milliseconds = Date.prototype.getTime.call(date);\n // An invalid Date has no ISO text: the eager key used to throw its RangeError here, so it still does.\n if (!Number.isFinite(milliseconds)) Date.prototype.toISOString.call(date);\n identities.set(date, {\n milliseconds,\n text,\n numeric: params.numeric,\n key: params.key,\n kind: params.kind ?? \"timestamp\",\n });\n return date;\n}\n\nfunction identityOf(params: { date: Date }): TimestampIdentity | undefined {\n const stored = identities.get(params.date);\n if (stored !== undefined && stored.milliseconds !== Date.prototype.getTime.call(params.date)) {\n identities.delete(params.date);\n return undefined;\n }\n return stored;\n}\n\n/** Exact equality key when available; caller-created/mutated Dates keep millisecond semantics. */\nexport function timestampIdentityKey(params: { date: Date }): string {\n const identity = identityOf(params);\n return identity !== undefined ? identityKey(identity) : `date:${Number.isFinite(Date.prototype.getTime.call(params.date)) ? Date.prototype.toISOString.call(params.date) : \"invalid\"}`;\n}\n\n/** Exact parameter text, valid only for an unchanged decoded Date. */\nexport function timestampIdentityText(params: { date: Date; kind?: TimestampIdentity[\"kind\"] }): string | undefined {\n const identity = identityOf(params);\n return identity !== undefined && (params.kind === undefined || identity.kind === params.kind) ? identity.text : undefined;\n}\n\n/** SQLite legacy integer epochs remain integers rather than being rewritten to ISO text. */\nexport function sqliteTimestampIdentityValue(params: { date: Date }): string | number | undefined {\n const identity = identityOf(params);\n return identity?.kind === \"sqlite\" ? identity.numeric ?? identity.text : undefined;\n}\n\n/** Compare retained native identities; SQLite text ordering remains the database's collation. */\nexport function compareTimestampDates(params: { left: Date; right: Date }): -1 | 0 | 1 | null {\n const left = identityOf({ date: params.left });\n const right = identityOf({ date: params.right });\n if (timestampIdentityKey({ date: params.left }) === timestampIdentityKey({ date: params.right })) return 0;\n const rank = (a: number | bigint | string, b: number | bigint | string): -1 | 0 | 1 => a < b ? -1 : a > b ? 1 : 0;\n if (left?.kind === \"sqlite\" || right?.kind === \"sqlite\") {\n return left?.numeric !== undefined && right?.numeric !== undefined ? rank(left.numeric, right.numeric) : null;\n }\n const clock = (identity: TimestampIdentity): readonly [bigint, number] => {\n const [, hours, minutes, seconds, offset] = identityKey(identity).split(\":\");\n const [whole, fraction = \"\"] = seconds!.split(\".\");\n const local = BigInt(Number(hours) * 3600 + Number(minutes) * 60 + Number(whole)) * 1_000_000_000n\n + BigInt(fraction.padEnd(9, \"0\"));\n const zone = Number(offset);\n // PostgreSQL timetz orders unwrapped UTC time, then seconds WEST of UTC.\n return [local - BigInt(zone) * 1_000_000n, -zone];\n };\n if ((left?.kind !== undefined && left.kind !== \"timestamp\") || (right?.kind !== undefined && right.kind !== \"timestamp\")) {\n if (left === undefined || right === undefined || left.kind !== right.kind) return null;\n const a = clock(left);\n const b = clock(right);\n return rank(a[0], b[0]) || rank(a[1], b[1]);\n }\n const milliseconds = rank(Date.prototype.getTime.call(params.left), Date.prototype.getTime.call(params.right));\n if (milliseconds !== 0) return milliseconds;\n const a = /\\.(\\d+)/.exec(left?.text ?? \"\")?.[1]?.slice(3) ?? \"\";\n const b = /\\.(\\d+)/.exec(right?.text ?? \"\")?.[1]?.slice(3) ?? \"\";\n return rank(a.padEnd(Math.max(a.length, b.length), \"0\"), b.padEnd(Math.max(a.length, b.length), \"0\"));\n}\n\n/** Snapshot the value and its valid database identity without sharing mutable state. */\nexport function cloneTimestampDate(params: { date: Date }): Date {\n const date = new Date(Date.prototype.getTime.call(params.date));\n const identity = identityOf(params);\n if (identity !== undefined) identities.set(date, identity);\n return date;\n}\n",
6
6
  "import type { QualifiedSqlName } from \"@vibeorm/schema\";\n\nconst NATIVE_ENUM_ARRAY_PARAMETER: unique symbol = Symbol(\"vibeorm.nativeEnumArrayParameter\");\n\n/** Encoded enum-array text plus its immutable physical type; never passed to a driver. */\nexport type NativeEnumArrayParameter = {\n readonly [NATIVE_ENUM_ARRAY_PARAMETER]: true;\n readonly value: string;\n readonly type: QualifiedSqlName;\n};\n\n/** Attach a typed native enum identity to centralized codec output, without re-encoding values. */\nexport function nativeEnumArrayParameter(params: { value: string; type: QualifiedSqlName }): NativeEnumArrayParameter {\n return { [NATIVE_ENUM_ARRAY_PARAMETER]: true, value: params.value, type: params.type };\n}\n\n/** Narrow the internal typed parameter before collecting its plain wire value. */\nexport function isNativeEnumArrayParameter(value: unknown): value is NativeEnumArrayParameter {\n return typeof value === \"object\" && value !== null && NATIVE_ENUM_ARRAY_PARAMETER in value;\n}\n",
@@ -16,7 +16,7 @@
16
16
  "/**\n * The pure codec tables — constitution rule 6.\n *\n * ONE place defines how a JS value becomes a driver parameter (`encode`) and\n * how a driver value becomes a JS value (`decode`), per dialect × scalar type.\n * Nothing else in any package may coerce: v1's BigInt-as-string, enum-array and\n * timestamp bugs all came from coercion scattered across query builders and\n * relation loaders (LEARNINGS.md).\n *\n * These tables are PURE — dialect × scalar type only, no schema/model\n * awareness. The FieldMeta-aware entry points (`getCodec`/`encodeValue`/\n * `decodeValue`/`decodeRow`/`decodeRows`) live in @vibeorm/runtime, which\n * re-exports these tables so existing consumers keep one import site.\n *\n * The two rules that make it work:\n * - EVERY parameter bound by the query builder passes through `encode`.\n * - EVERY row materialized by the client passes through `decode` — including\n * every relation-loaded child row (the v1 lesson).\n *\n * Database enums ride the String codec. String-backed enums use the field-bound\n * membership codec below; their wire values are still strings on every dialect.\n */\n\nimport { VibeError, invalidStoredData, isCanonicalLocalDate, timeOfDayType } from \"@vibeorm/schema\";\nimport type { Dialect, ScalarType } from \"@vibeorm/schema\";\nimport { rememberTimestampIdentity, sqliteTimestampIdentityValue, timestampIdentityText } from \"./timestamp-identity.ts\";\n\n// ─── Types ────────────────────────────────────────────────────────\n\n/**\n * One scalar type's transport rules for one dialect. Both directions see only\n * non-null values — the runtime's `encodeValue`/`decodeValue` short-circuit\n * null/undefined.\n */\nexport type ScalarCodec = {\n readonly encode: (value: unknown) => unknown;\n readonly decode: (value: unknown) => unknown;\n};\n\nexport type CodecTable = Readonly<Record<ScalarType, ScalarCodec>>;\n\n/** Field-bound membership for string-backed enums; constructed once per field, not per value. */\nexport function enumMembershipCodec(params: {\n model: string;\n field: string;\n enum: string;\n members: readonly string[];\n}): ScalarCodec {\n const { model, field, enum: enumName } = params;\n const members: ReadonlySet<string> = new Set(params.members);\n return {\n encode: (value) => {\n if (typeof value === \"string\" && members.has(value)) return value;\n throw new VibeError({\n code: \"VIBE_VALIDATION\",\n message: `Invalid value for enum ${enumName} on ${model}.${field}`,\n meta: { model, field, enum: enumName },\n });\n },\n decode: (value) => {\n if (typeof value === \"string\" && members.has(value)) return value;\n throw invalidStoredData({ model, field, enum: enumName, value });\n },\n };\n}\n\n// ─── Wire fidelity (board #30) ────────────────────────────────────\n\n/**\n * What a DRIVER actually delivers for NON-LIST **base-table storage** columns\n * on its result path — declared per adapter (`DatabaseAdapter.wire`), verified\n * live per driver, and consumed by the runtime's decode plans to skip decoders\n * that are provably no-ops for that driver. The claims hold because base-table\n * storage types follow the declared field types by construction (migrate's\n * mappings); VIEW columns can hide any expression type under a declared field\n * type (mysql `COUNT(*)` is BIGINT-as-string under an `Int` field), so the\n * runtime exempts views from pruning entirely.\n *\n * Why it exists: the codec tables above are keyed per DIALECT, but wire forms\n * differ per DRIVER (node-postgres hands `Date` objects where a text-mode\n * driver hands strings). Without a declaration every DateTime/Json/Int column\n * pays an idempotency probe per row per read; with one, the decode plan keeps\n * only decoders that do real work. The codec DEFINITIONS stay right here —\n * rule 6 — only plan membership changes, and only under a declaration.\n *\n * An adapter that declares nothing gets the full idempotency-guarded plan\n * (today's behaviour). Declarations are PROMISES: declare only what the\n * driver verifiably does.\n */\nexport type WireFidelity = {\n /** DateTime columns arrive as JS `Date` instances (`\"native\"`) or as text/number (`\"text\"`). */\n readonly dateTime?: \"native\" | \"text\";\n /** Json columns arrive already parsed (`\"parsed\"`) or as raw JSON text (`\"text\"`). */\n readonly json?: \"parsed\" | \"text\";\n /** Int/Float columns arrive as JS numbers (`\"native\"`) or as text (`\"text\"`). */\n readonly numbers?: \"native\" | \"text\";\n /**\n * Bytes columns arrive as Node `Buffer` instances (`\"buffer\"`: node-postgres,\n * bun:sql); absent means a plain `Uint8Array` (PGlite). Never prunes a\n * decoder: the runtime's JSON-transport plan reads it, so a `\"join\"`\n * relation child's bytes (base64 on the wire) materialize in the same class\n * the driver hands the `\"query\"` strategy — value identity (5.0 lane V).\n */\n readonly bytes?: \"buffer\";\n /**\n * Zone-less date-time text (MySQL DATETIME / TIMESTAMP / DATE) is read as a\n * UTC instant by the driver (`\"utc\"`: mysql2 with `timezone: \"Z\"`). Absent\n * means another or an unknown zone (another `timezone` option, an injected\n * pool). Never prunes a decoder: the runtime reads it to decide whether a\n * dialect default of `\"join\"` keeps value identity — the JSON transport\n * decodes that text as UTC (`lateralJson.requiresUtcDateTimeWire`, lane J).\n */\n readonly zoneLessDateTime?: \"utc\";\n};\n\n/**\n * Is this scalar type's DECODE a no-op under the declared wire fidelity?\n * Provable against the decode implementations in this file, identically on\n * every dialect table:\n *\n * - `DateTime` always validates finiteness. A native-wire claim does not\n * exclude PostgreSQL infinity, and some drivers return Invalid Date for it.\n * - `Json` + `json: \"parsed\"` — {@link jsonCodec}'s decode returns non-strings\n * unchanged. (For a driver that pre-parses, skipping is also the CORRECT\n * reading of a stored top-level JSON **string**: the driver hands a bare JS\n * string, which the guarded decode would wrongly re-parse.)\n * - `Int`/`Float` + `numbers: \"native\"` — {@link numberCodec}'s decode returns\n * numbers unchanged.\n *\n * Everything else always decodes: BigInt (string→BigInt is real work on every\n * driver that can't send int64), Decimal (mysql pads), Boolean (0/1→boolean),\n * Bytes, and every LIST field (array wire forms differ per driver and are not\n * covered by the declaration) — with ONE exception the runtime applies (F13):\n * `Json` + `json: \"parsed\"` extends to list ELEMENTS, because a driver that\n * parses json parses the elements of a json ARRAY too (verified live:\n * node-postgres and PGlite both return `ARRAY['\"123\"'::jsonb]` as the JS\n * string `\"123\"`). The same `json` claim is the only one the runtime keeps\n * over a VIEW — it is a promise about the DRIVER's result path, while the\n * `dateTime`/`numbers` claims depend on the expression type a view can hide.\n */\nexport function decodeIsNoop(params: { scalarType: ScalarType; wire: WireFidelity | undefined }): boolean {\n const { scalarType, wire } = params;\n if (wire === undefined) return false;\n if (scalarType === \"DateTime\") return false;\n if (scalarType === \"Json\") return wire.json === \"parsed\";\n if (scalarType === \"Int\" || scalarType === \"Float\") return wire.numbers === \"native\";\n return false;\n}\n\n// ─── Shared codec pieces ──────────────────────────────────────────\n\nconst identity = (value: unknown): unknown => value;\n\n/** Values that already are what the driver wants, in both directions. */\nconst passthroughCodec: ScalarCodec = { encode: identity, decode: identity };\n\n/** Numbers that some drivers hand back as text (numeric-ish column types). */\nconst numberCodec: ScalarCodec = {\n encode: identity,\n decode: (value) => (typeof value === \"string\" ? Number(value) : value),\n};\n\n/**\n * BigInt. No driver serializes a JS `bigint` parameter, so it always goes out\n * as text; sqlite's INTEGER affinity converts it back on the way in. Incoming\n * values arrive as strings (postgres `int8`, mysql `BIGINT`) or numbers.\n */\nconst bigIntCodec: ScalarCodec = {\n encode: (value) => (typeof value === \"bigint\" ? value.toString() : value),\n decode: (value) => {\n if (typeof value === \"bigint\") return value;\n if (typeof value === \"string\" && /^[+-]?\\d+$/.test(value.trim())) return BigInt(value.trim());\n if (typeof value === \"number\" && Number.isSafeInteger(value)) return BigInt(value);\n throw new VibeError({ code: \"VIBE_DATA_INVALID\", message: \"BigInt requires an integer string or a safe integer\", meta: { value } });\n },\n};\n\n/**\n * Decimal stays a string in JS, in both directions and on every dialect: no\n * float rounding, and no decimal library forced on the consumer. Numbers and\n * bigints passed in are stringified rather than silently losing precision.\n *\n * Decode is identity on postgres and sqlite: both preserve the scale the\n * value was WRITTEN with (`numeric` keeps the input's display scale; sqlite\n * stores the text), so `\"12.340\"` round-trips as `\"12.340\"` — trimming would\n * destroy information the engine kept. MySQL cannot preserve it (fixed-scale\n * DECIMAL) and gets its own decode — see {@link mysqlDecimalCodec}.\n */\nconst decimalCodec: ScalarCodec = {\n encode: (value) => (typeof value === \"number\" || typeof value === \"bigint\" ? String(value) : value),\n decode: identity,\n};\n\n/**\n * MySQL Decimal: same encode, but decode trims the fixed-scale padding.\n * MySQL's DECIMAL is fixed-scale, so the written scale is unrecoverable and\n * every value comes back padded to the column's full scale — verified live on\n * 8.4, `DECIMAL(65, 30)` returns `\"42.420000000000000000000000000000\"` where\n * postgres/sqlite return `\"42.42\"`. Trailing FRACTIONAL zeros (and a\n * then-dangling point) are an artifact of storage, not the value, so decode\n * trims them to the minimal exact string. Integer zeros are never touched.\n */\nconst mysqlDecimalCodec: ScalarCodec = {\n encode: decimalCodec.encode,\n decode: (value) => {\n if (typeof value !== \"string\" || !value.includes(\".\")) return value;\n const trimmed = value.replace(/0+$/, \"\").replace(/\\.$/, \"\");\n return trimmed === \"\" || trimmed === \"-\" ? \"0\" : trimmed;\n },\n};\n\n// ─── Zone-less date-time text ─────────────────────────────────────\n\n/**\n * `YYYY-MM-DD[T ]HH:MM[:SS[.fraction]]` carrying NO zone: the text form of a\n * postgres `timestamp without time zone` (row wire, PGlite, and the join\n * strategy's JSON transport) and of a mysql `DATETIME`.\n */\nconst ZONE_LESS_DATETIME = /^\\d{4}-\\d{2}-\\d{2}[T ]\\d{2}:\\d{2}(?::\\d{2}(?:\\.\\d{1,9})?)?$/;\n\n/**\n * The postgres TEXT form of a `timestamptz`: `2024-06-01 12:34:56.789+00`,\n * `+05:30`, `-03`. JavaScriptCore reads a space-separated date with a bare\n * `+HH` offset unreliably (`0001-01-01 00:00:00+00` parses as the year 2001),\n * so it is rewritten to ISO-8601 (`T`, `+HH:MM`) first. Offsets with seconds\n * (historic local mean time) fall through to the engine.\n */\nconst PG_ZONED_DATETIME = /^(\\d{4}-\\d{2}-\\d{2})[T ](\\d{2}:\\d{2}(?::\\d{2})?)(\\.\\d{1,9})?([+-]\\d{2})(?::?(\\d{2}))?$/;\n\n/** The fields {@link parseExtendedDateTimeText} reads: year (4+ digits), date, optional time, fraction, offset (with seconds), era. */\nconst EXTENDED_DATETIME = /^(\\d{4,})-(\\d{2})-(\\d{2})(?:[T ](\\d{2}):(\\d{2})(?::(\\d{2})(?:\\.(\\d{1,9}))?)?)?(?:([+-])(\\d{2})(?::?(\\d{2}))?(?::?(\\d{2}))?)?( BC)?$/;\n\n/**\n * Parse date-time text into a `Date`, reading ZONE-LESS text as **UTC**.\n *\n * ECMA-262 reads `2026-01-15T12:00:00` as process-LOCAL time, so the same\n * stored value would decode to a different instant on every host time zone,\n * and to a different instant than bun:sql (UTC) or Prisma (UTC for\n * `@db.Timestamp`) return for the same row. Treat-as-UTC is the only reading\n * that yields ONE instant everywhere (MYSQL-2, live-proven; the postgres\n * `timestamp` case is proven by apps/tests `timestamp-zones.e2e`). Text with\n * an explicit `Z`/offset and date-only text parse as ECMA-262 already reads\n * them (as written / UTC midnight); anything unparseable is `undefined` so the\n * caller keeps its own fallback. Fractions beyond milliseconds are truncated —\n * `Date` has no finer resolution and engines differ on longer fractions.\n */\nexport function parseDateTimeText(params: { text: string }): Date | undefined {\n const trimmed = params.text.trim();\n const date = parseDateTimeInstant({ trimmed });\n return date === undefined ? undefined : rememberTimestampIdentity({ date, text: trimmed });\n}\n\n/**\n * {@link parseDateTimeText}'s instant without its identity record — for a caller that records its own (A-02).\n *\n * RD-08 fast paths, both EXACT by construction (they only skip work whose\n * outcome is already known, so every text decodes to the same instant):\n * - text ending in `Z` (SQLite's canonical `2026-01-01T00:00:00.000Z`): both\n * regular expressions below need a trailing digit, so today's path always\n * ended in `new Date(trimmed)`;\n * - PostgreSQL's JSON form `YYYY-MM-DDTHH:MM:SS[.sss]±HH:MM` (25 or 29\n * characters, the join strategy's transport): `ZONE_LESS_DATETIME` cannot\n * match a sign, and `PG_ZONED_DATETIME` rebuilds exactly this text (`T`, a\n * fraction of at most three digits, `±HH:MM`) before the same `new Date`.\n */\nfunction parseDateTimeInstant(params: { trimmed: string }): Date | undefined {\n const { trimmed } = params;\n const length = trimmed.length;\n if (\n (length > 0 && trimmed.charCodeAt(length - 1) === 90) ||\n ((length === 25 || (length === 29 && trimmed.charCodeAt(19) === 46)) &&\n trimmed.charCodeAt(10) === 84 &&\n trimmed.charCodeAt(length - 3) === 58 &&\n (trimmed.charCodeAt(length - 6) === 43 || trimmed.charCodeAt(length - 6) === 45))\n ) {\n const parsed = new Date(trimmed);\n return Number.isNaN(parsed.getTime()) ? undefined : parsed;\n }\n if (ZONE_LESS_DATETIME.test(trimmed)) {\n const asUtc = new Date(`${trimmed.replace(\" \", \"T\").replace(/(\\.\\d{3})\\d+$/, \"$1\")}Z`);\n if (!Number.isNaN(asUtc.getTime())) return asUtc;\n }\n const zoned = PG_ZONED_DATETIME.exec(trimmed);\n if (zoned !== null) {\n const [, date, time, fraction, hours, minutes] = zoned;\n const iso = new Date(`${date}T${time}${(fraction ?? \"\").slice(0, 4)}${hours}:${minutes ?? \"00\"}`);\n if (!Number.isNaN(iso.getTime())) return iso;\n }\n const extended = parseExtendedDateTimeText({ text: trimmed });\n if (extended !== undefined) return extended;\n const parsed = new Date(trimmed);\n return Number.isNaN(parsed.getTime()) ? undefined : parsed;\n}\n\n/**\n * PostgreSQL date/time text with a year of five or more digits or a ` BC` era,\n * in the row text form and the JSON form: `12345-06-07 08:09:10.111+00`,\n * `12345-06-07T08:09:10.111` (zone-less), `0044-03-15T12:00:00.5+00:00 BC`,\n * `0044-03-15 BC` (`date`). ECMA-262 parses none of them (an expanded year\n * needs `+012345`), and a value near the end of year 9999 reaches them\n * through the session zone alone (`9999-12-31 23:59+00` prints as\n * `10000-01-01 00:59+01` east of UTC). Built from its fields, by the rules of\n * {@link parseDateTimeText}: the BC year astronomically (`1 BC` = year 0, the\n * reading of node-postgres), zone-less text as UTC, the fraction truncated to\n * milliseconds, an offset with seconds applied exactly.\n *\n * `undefined` for every other text — a 4-digit AD value keeps the parse it\n * had — and for an instant outside the `Date` range. Exported for the adapters\n * whose zone-less driver parsers fall back to it (one rule, rule 6).\n */\nexport function parseExtendedDateTimeText(params: { text: string }): Date | undefined {\n const match = EXTENDED_DATETIME.exec(params.text.trim());\n if (match === null) return undefined;\n const [, yearText, month, day, hours, minutes, seconds, fraction, sign, offsetHours, offsetMinutes, offsetSeconds, era] = match;\n if ((yearText as string).length < 5 && era === undefined) return undefined;\n const year = era === undefined ? Number(yearText) : 1 - Number(yearText);\n const date = new Date(0);\n date.setUTCFullYear(year, Number(month) - 1, Number(day));\n date.setUTCHours(Number(hours ?? 0), Number(minutes ?? 0), Number(seconds ?? 0), Number((fraction ?? \"\").padEnd(3, \"0\").slice(0, 3)));\n if (sign !== undefined) {\n const offset = (Number(offsetHours) * 3600 + Number(offsetMinutes ?? 0) * 60 + Number(offsetSeconds ?? 0)) * 1000;\n date.setTime(date.getTime() - (sign === \"-\" ? -offset : offset));\n }\n return Number.isNaN(date.getTime()) ? undefined : date;\n}\n\n/**\n * The decode refusal of a non-finite or unparseable DateTime — one error for\n * every DateTime codec. Exported so a statement that refuses such a value\n * itself (the runtime's in-statement value guard, round-trip follow-up D1)\n * reports exactly this error.\n */\nexport function decodedDateTimeRefusal(): VibeError {\n return new VibeError({ code: \"VIBE_DATA_INVALID\", message: \"DateTime requires a finite timestamp; use an explicit extended timestamp decoder for infinity\" });\n}\n\nfunction invalidDecodedDateTime(): never {\n throw decodedDateTimeRefusal();\n}\n\n/**\n * DateTime where the driver speaks `Date` objects (postgres, mysql). Text\n * reaching decode (the join strategy's JSON transport, a text-mode driver)\n * goes through {@link parseDateTimeText}: zone-less text is UTC.\n */\nconst dateNativeCodec: ScalarCodec = {\n encode: (value) => {\n if ((value instanceof Date && !Number.isFinite(value.getTime())) || (typeof value === \"number\" && !Number.isFinite(value)) || (typeof value === \"string\" && /^[+-]?infinity$/i.test(value.trim()))) {\n throw new VibeError({ code: \"VIBE_VALIDATION\", message: \"DateTime parameters require finite timestamps; use an extended timestamp encoder for infinity\" });\n }\n return value instanceof Date ? timestampIdentityText({ date: value }) ?? value : value;\n },\n decode: (value) => {\n const date = value instanceof Date ? value\n : typeof value === \"string\" ? parseDateTimeText({ text: value })\n : typeof value === \"number\" ? new Date(value) : undefined;\n if (date !== undefined && Number.isFinite(date.getTime())) return date;\n return invalidDecodedDateTime();\n },\n};\n\n/** DateTime on sqlite: stored as ISO-8601 UTC text (explicit `Z`), parsed back on read. */\nconst dateTextCodec: ScalarCodec = {\n encode: (value) => {\n dateNativeCodec.encode(value);\n const date = value instanceof Date ? value\n : typeof value === \"string\" ? parseDateTimeText({ text: value })\n : typeof value === \"number\" ? new Date(value) : undefined;\n if (date !== undefined && Number.isFinite(date.getTime())) return value instanceof Date ? sqliteTimestampIdentityValue({ date: value }) ?? date.toISOString() : date.toISOString();\n throw new VibeError({ code: \"VIBE_VALIDATION\", message: \"DateTime parameters require a valid finite timestamp\" });\n },\n decode: (value) => {\n if (typeof value === \"string\") {\n // A-02: parse once and record ONE identity — the sqlite one (the shared\n // parse used to record a timestamp identity first, then this overwrote it).\n const date = parseDateTimeInstant({ trimmed: value.trim() });\n if (date === undefined || !Number.isFinite(date.getTime())) return invalidDecodedDateTime();\n return rememberTimestampIdentity({ date, text: value, key: `date:${value}`, kind: \"sqlite\" });\n }\n const date = dateNativeCodec.decode(value) as Date;\n if (typeof value === \"number\") return rememberTimestampIdentity({ date, text: date.toISOString(), numeric: value, key: `epoch:${value}`, kind: \"sqlite\" });\n return date;\n },\n};\n\n/**\n * DateTime on mysql (N4 + MYSQL-2): mysql2 serializes `Date` per the\n * adapter's pinned `timezone: \"Z\"`, but passes STRINGS verbatim — an ISO-8601\n * string operand hard-errors on strict-mode servers (1292). Encode normalizes\n * parseable strings/numbers to `Date` through {@link parseDateTimeText} —\n * ZONE-LESS strings (`2026-01-15T12:00:00`, `2026-01-15 12:00:00`) parse as\n * UTC, never process-local time (MYSQL-2, live-proven: TZ=America/New_York\n * stored 17:00Z for a noon literal): postgres under the session's pinned UTC\n * parses the same literal as UTC, so treat-as-UTC is the only reading that\n * stores the SAME instant on both dialects. Strings with an explicit Z/offset\n * parse as written; garbage passes through so the driver's own error names it.\n */\nconst mysqlDateCodec: ScalarCodec = {\n encode: (value) => {\n dateNativeCodec.encode(value);\n if (value instanceof Date) {\n const text = timestampIdentityText({ date: value, kind: \"timestamp\" });\n if (text !== undefined) {\n // MySQL parameters need zone-less UTC text, not a driver Date or ISO Z.\n const fraction = /\\.(\\d+)/.exec(text)?.[1] ?? \"\";\n return value.toISOString().replace(\"T\", \" \").replace(/\\.\\d{3}Z$/, `.${fraction.padEnd(3, \"0\")}`);\n }\n return value;\n }\n if (typeof value === \"number\") {\n const parsed = new Date(value); // epoch millis — zone-free by definition\n if (!Number.isNaN(parsed.getTime())) return parsed;\n return value;\n }\n if (typeof value === \"string\") return parseDateTimeText({ text: value }) ?? value;\n return value;\n },\n decode: dateNativeCodec.decode,\n};\n\n// ─── Time of day (`@db.Time` / `@db.Timetz`) ───────────────────────\n\nconst MILLISECONDS_PER_DAY = 86_400_000;\n\n/**\n * Time-of-day text as postgres (`time`, `timetz`, also inside JSON) and mysql\n * (`TIME`) print it: `HH:MM[:SS[.fraction]]`, then for timetz an offset\n * `+HH`, `+HH:MM` or `+HH:MM:SS`. Hours are two digits: a mysql duration\n * beyond a day (`838:59:59`) or below zero (`-01:00:00`) is not a time of day.\n */\nconst TIME_OF_DAY_TEXT = /^(\\d{2}):(\\d{2})(?::(\\d{2})(?:\\.(\\d{1,9}))?)?(?:([+-])(\\d{2})(?::?(\\d{2}))?(?::?(\\d{2}))?)?$/;\n\nconst pad = (value: number, width: number): string => String(value).padStart(width, \"0\");\n\n/** Milliseconds since midnight UTC of a finite instant. */\nconst utcMillisecondOfDay = (date: Date): number =>\n ((date.getTime() % MILLISECONDS_PER_DAY) + MILLISECONDS_PER_DAY) % MILLISECONDS_PER_DAY;\n\n/** `HH:MM:SS.mmm` for a millisecond of the day. */\nconst timeOfDayText = (millisecond: number): string =>\n `${pad(Math.floor(millisecond / 3_600_000), 2)}:${pad(Math.floor(millisecond / 60_000) % 60, 2)}:${pad(Math.floor(millisecond / 1000) % 60, 2)}.${pad(millisecond % 1000, 3)}`;\n\n/**\n * The time-of-day codec — Prisma's contract for `DateTime @db.Time(n)` and\n * `@db.Timetz(n)` (release 3.0 decision D2), identical on every dialect that\n * holds the type (`DialectCapabilities.timeOfDayTypes`):\n *\n * - encode: the UTC time of day of the `Date` with millisecond precision,\n * `HH:MM:SS.mmm`, plus `+00` for timetz. The date part is dropped. A string\n * or epoch-millisecond number is read as an instant first (zone-less text is\n * UTC, {@link parseDateTimeText}). The full instant must never reach the\n * driver: postgres refuses `1970-01-01T13:14:15.123Z` for `time` (22007),\n * and PGlite sends a `Date` as `Date#toString()` (host-local).\n * - decode: a `Date` at `1970-01-01` with that UTC time of day. A timetz\n * offset is applied first and the result wraps into the same day\n * (`01:00:00+02` → `1970-01-01T23:00:00.000Z`); postgres's `24:00:00` wraps\n * to midnight. Fractions beyond milliseconds are truncated, as for every\n * DateTime. A driver `Date` keeps only its UTC time of day.\n *\n * Not a table row: the runtime routes a DateTime field whose native type is a\n * time of day here ({@link timeOfDayCodec}), like `float32Codec` for `@db.Real`.\n */\nfunction makeTimeOfDayCodec(params: { zoned: boolean }): ScalarCodec {\n const suffix = params.zoned ? \"+00\" : \"\";\n return Object.freeze({\n encode: (value: unknown): unknown => {\n dateNativeCodec.encode(value);\n const date = value instanceof Date ? value\n : typeof value === \"string\" ? parseDateTimeText({ text: value })\n : typeof value === \"number\" ? new Date(value) : undefined;\n if (date === undefined || !Number.isFinite(date.getTime())) {\n throw new VibeError({ code: \"VIBE_VALIDATION\", message: \"a time-of-day DateTime parameter requires a valid finite Date\", meta: { value } });\n }\n return timestampIdentityText({ date, kind: params.zoned ? \"timetz\" : \"time\" }) ?? `${timeOfDayText(utcMillisecondOfDay(date))}${suffix}`;\n },\n decode: (value: unknown): unknown => {\n if (value instanceof Date && Number.isFinite(value.getTime())) {\n if (timestampIdentityText({ date: value, kind: params.zoned ? \"timetz\" : \"time\" }) !== undefined) return value;\n const milliseconds = utcMillisecondOfDay(value);\n const text = timeOfDayText(milliseconds);\n return rememberTimestampIdentity({ date: new Date(milliseconds), text: `${text}${suffix}`, key: `${params.zoned ? \"timetz\" : \"time\"}:${text}:0`, kind: params.zoned ? \"timetz\" : \"time\" });\n }\n const match = typeof value === \"string\" ? TIME_OF_DAY_TEXT.exec(value.trim()) : null;\n if (match !== null) {\n const [, hours, minutes, seconds, fraction, sign, offsetHours, offsetMinutes, offsetSeconds] = match;\n const millisecond = Number(hours) * 3_600_000 + Number(minutes) * 60_000 + Number(seconds ?? 0) * 1000\n + Number((fraction ?? \"\").slice(0, 3).padEnd(3, \"0\"));\n const offset = sign === undefined ? 0\n : (sign === \"-\" ? -1 : 1) * (Number(offsetHours) * 3_600_000 + Number(offsetMinutes ?? 0) * 60_000 + Number(offsetSeconds ?? 0) * 1000);\n if (millisecond <= MILLISECONDS_PER_DAY) {\n const date = new Date((((millisecond - offset) % MILLISECONDS_PER_DAY) + MILLISECONDS_PER_DAY) % MILLISECONDS_PER_DAY);\n const exactFraction = (fraction ?? \"\").padEnd(3, \"0\").replace(/(?<=\\d{3})0+$/, \"\");\n // PostgreSQL date.c:timetz_cmp_internal equates values only when\n // BOTH local time and zone agree. Do not key by the wrapped UTC Date:\n // 14:00+02 differs from 12:00+00, and 24:00 differs from 00:00.\n const key = `${params.zoned ? \"timetz\" : \"time\"}:${hours}:${minutes}:${seconds ?? \"00\"}.${exactFraction}:${offset}`;\n return rememberTimestampIdentity({ date, text: (value as string).trim(), key, kind: params.zoned ? \"timetz\" : \"time\" });\n }\n }\n throw new VibeError({ code: \"VIBE_DATA_INVALID\", message: \"a time-of-day DateTime column returned a value that is not a time of day\", meta: { value } });\n },\n });\n}\n\nconst timeCodec: ScalarCodec = makeTimeOfDayCodec({ zoned: false });\nconst timetzCodec: ScalarCodec = makeTimeOfDayCodec({ zoned: true });\n\n/**\n * The time-of-day codec for a DateTime field's native type, or `undefined`\n * when the native type is not `time`/`timetz` (the DateTime table row\n * applies). The one native-type rule is `timeOfDayType` in @vibeorm/schema,\n * shared with the dialect refusal in schema validation.\n */\nexport function timeOfDayCodec(params: { nativeType: string | undefined }): ScalarCodec | undefined {\n const type = timeOfDayType({ nativeType: params.nativeType });\n return type === \"timetz\" ? timetzCodec : type === \"time\" ? timeCodec : undefined;\n}\n\n/** Canonical calendar-day text only; a driver Date cannot recover the authored day. */\nexport const localDateCodec: ScalarCodec = Object.freeze({\n encode: (value: unknown): string => {\n const candidate = { value };\n if (isCanonicalLocalDate(candidate)) return candidate.value;\n throw new VibeError({\n code: \"VIBE_VALIDATION\",\n message: \"A local date requires canonical YYYY-MM-DD text for a real date in years 0001–9999\",\n meta: { value },\n });\n },\n decode: (value: unknown): string => {\n const candidate = { value };\n if (isCanonicalLocalDate(candidate)) return candidate.value;\n throw new VibeError({\n code: \"VIBE_DATA_INVALID\",\n message: \"A local-date column returned noncanonical or out-of-domain calendar-day text\",\n meta: { value },\n });\n },\n});\n\n/** Booleans stored as 0/1 (sqlite INTEGER). */\nconst booleanIntCodec: ScalarCodec = {\n encode: (value) => (typeof value === \"boolean\" ? (value ? 1 : 0) : value),\n decode: (value) => (typeof value === \"number\" ? value !== 0 : value),\n};\n\n/**\n * MySQL reads TINYINT(1) as numeric 0/1 and LONGLONG predicates as exact text\n * when bigNumberStrings is enabled. Encoding still sends booleans natively.\n */\nconst booleanNativeInCodec: ScalarCodec = {\n encode: identity,\n decode: (value) => value === \"0\" ? false : value === \"1\" ? true : booleanIntCodec.decode(value),\n};\n\n/**\n * Parse stored JSON text at the centralized codec boundary. A supplied context\n * marks a bound field: its error contains only that context, never the document\n * or the native parser cause. Without context, legacy codec errors are unchanged.\n */\nexport function parseJsonText(params: {\n text: string;\n context?: Readonly<Record<string, unknown>>;\n}): unknown {\n const { text, context } = params;\n try {\n return JSON.parse(text);\n } catch (cause) {\n if (context !== undefined) {\n throw new VibeError({\n code: \"VIBE_INTERNAL\",\n message: \"a bound Json field returned text that is not valid JSON\",\n meta: { ...context },\n });\n }\n throw new VibeError({\n code: \"VIBE_INTERNAL\",\n message: \"a Json column returned text that is not valid JSON\",\n meta: { value: text },\n cause,\n });\n }\n}\n\n/**\n * JSON is serialized by US, on every dialect, and never handed to a driver as a\n * live object. Two reasons: drivers disagree (node-postgres stringifies objects,\n * bun:sqlite and mysql2 do not), and a JSON payload that happens to look like an\n * atomic UPDATE operation must never reach the SQL AST as an object\n * (see `isSetOperation` in ast.ts). Reads arrive as text on postgres and\n * sqlite, and already parsed from mysql2's JSON columns.\n */\nconst jsonCodec: ScalarCodec = {\n encode: (value) => JSON.stringify(value),\n decode: (value) => {\n if (typeof value !== \"string\") return value;\n return parseJsonText({ text: value });\n },\n};\n\n// ─── float32 (`Float @db.Real`) ──────────────────────────────────\n\n/**\n * The SHORTEST decimal that round-trips through float32 to the same value as\n * `value` — what postgres itself prints for a `real` (`0.1`, `3.4028235e+38`).\n *\n * A driver that reads a `real` in BINARY format (bun:sql with named\n * statements) hands back the float32 widened to float64:\n * `0.10000000149011612` for a stored `0.1`. Text-format drivers already give\n * the short form, and for those this is the identity — the shortest form of a\n * short value is itself — so it is safe on every driver. Smallest `p` in 1..9\n * with `fround(toPrecision(p)) === fround(value)`; nine significant digits\n * always identify a float32. `±0`, NaN and ±Infinity pass through.\n */\nexport function shortestFloat32(params: { value: number }): number {\n const { value } = params;\n if (value === 0 || !Number.isFinite(value)) return value;\n const target = Math.fround(value);\n for (let precision = 1; precision <= 9; precision++) {\n const candidate = Number(value.toPrecision(precision));\n if (Math.fround(candidate) === target) return candidate;\n }\n return value;\n}\n\n/**\n * `Float @db.Real` — a refinement of the Float codec keyed by the native type,\n * not by the scalar type, so it is not a table row: the runtime routes a\n * field with `nativeType: \"Real\"` here. Decode = {@link numberCodec} then\n * {@link shortestFloat32}. Real aggregates that postgres returns as `real`\n * (`min`/`max`/`sum`) use it too; `avg` returns double precision and must not.\n */\nexport const float32Codec: ScalarCodec = {\n encode: identity,\n decode: (value) => {\n const number = typeof value === \"string\" ? Number(value) : value;\n return typeof number === \"number\" ? shortestFloat32({ value: number }) : number;\n },\n};\n\n// ─── postgres array-literal elements ────────────────────────────\n\nconst booleanFromText = (text: string): unknown => (text === \"t\" ? true : text === \"f\" ? false : text);\n\n/** bytea TEXT output (`\\x0102`, the default `bytea_output = hex`). */\nconst bytesFromText = (text: string): unknown =>\n /^\\\\x(?:[0-9a-fA-F]{2})*$/.test(text) ? new Uint8Array(Buffer.from(text.slice(2), \"hex\")) : text;\n\n/**\n * Element decoders for a postgres array that arrived as its TEXT literal\n * (`{1e-07,NULL}`, `{\"{\\\"a\\\": 1}\"}`) — the runtime projects `Float[]`/`Json[]`\n * as `::text`, and drivers return arrays whose type OID they do not know\n * (`uuid[]` on bun:sql; `xml[]`, `bit[]`, `citext[]` on node-postgres) as the\n * literal. Each element is postgres's text output for its type:\n *\n * - Boolean `t`/`f`, Bytes `\\x` hex and Json text need their own conversion;\n * - every other scalar's regular postgres codec already accepts the text form\n * (`Number(\"1e-07\")`, `Number(\"NaN\")`, `Number(\"-0\")`, BigInt/Decimal text,\n * `parseDateTimeText` for `2024-06-01 12:34:56.789+00`), so `null` means\n * \"decode with the field's own codec\".\n */\nexport function postgresArrayElementFromText(params: { scalarType: ScalarType }): ((text: string) => unknown) | null {\n switch (params.scalarType) {\n case \"Boolean\":\n return booleanFromText;\n case \"Bytes\":\n return bytesFromText;\n case \"Json\":\n return jsonCodec.decode as (text: string) => unknown;\n default:\n return null;\n }\n}\n\n// ─── Per-dialect tables ───────────────────────────────────────────\n\n/** postgres (and pglite — same wire behaviour). */\nexport const POSTGRES_CODECS: CodecTable = {\n String: passthroughCodec,\n Boolean: passthroughCodec,\n Int: numberCodec,\n BigInt: bigIntCodec,\n Float: numberCodec,\n Decimal: decimalCodec,\n DateTime: dateNativeCodec,\n Json: jsonCodec,\n Bytes: passthroughCodec,\n};\n\n/** sqlite — no boolean, date or json types; everything rides TEXT/INTEGER. */\nexport const SQLITE_CODECS: CodecTable = {\n String: passthroughCodec,\n Boolean: booleanIntCodec,\n Int: numberCodec,\n BigInt: bigIntCodec,\n Float: numberCodec,\n Decimal: decimalCodec,\n DateTime: dateTextCodec,\n Json: jsonCodec,\n Bytes: passthroughCodec,\n};\n\n/** mysql — native DATETIME and JSON, booleans stored as TINYINT(1). */\nexport const MYSQL_CODECS: CodecTable = {\n String: passthroughCodec,\n Boolean: booleanNativeInCodec,\n Int: numberCodec,\n BigInt: bigIntCodec,\n Float: numberCodec,\n Decimal: mysqlDecimalCodec,\n DateTime: mysqlDateCodec,\n Json: jsonCodec,\n Bytes: passthroughCodec,\n};\n\n/** The whole table, keyed by dialect. */\nexport const DIALECT_CODECS: Readonly<Record<Dialect, CodecTable>> = {\n postgres: POSTGRES_CODECS,\n sqlite: SQLITE_CODECS,\n mysql: MYSQL_CODECS,\n};\n",
17
17
  "// The query entry is a separate bundle. Its existing authenticity maps must\n// participate in ordinary value admission as well as reusable input admission.\nconst checks = new Set<(value: object) => boolean>();\n\n/** @internal Register a bundle's existing SQL-handle identity check, not object shapes. */\nexport function registerSqlHandleCheck(params: { check: (value: object) => boolean }): void {\n checks.add(params.check);\n}\n\n/** @internal Authentic SQL code cannot become parameter data, including nested values. */\nexport function isSqlHandle(value: object): boolean {\n for (const check of checks) if (check(value)) return true;\n return false;\n}\n",
18
18
  "import { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\n\n/** Physical schema queries; callers name each namespace without changing search_path. */\nexport type PostgresPhysicalCatalogQuery = \"tables\" | \"views\" | \"columns\" | \"constraints\" | \"checks\" | \"foreignKeys\" | \"enums\" | \"indexes\";\n\n/**\n * Read namespace-qualified physical metadata, preserving catalog type and index identities.\n * Extension members (`pg_depend.deptype = 'e'`) are left out of `tables`, `views` and `enums`:\n * the extension's own script owns them, so no plan may create or drop them. The other reads hang\n * off a table and reach the schema only through the filtered table list; PostgreSQL never records\n * an index or a constraint as an extension member on its own.\n */\nexport function renderPostgresPhysicalCatalog(params: { dialect: SqlDialect; namespace: string; query: PostgresPhysicalCatalogQuery }): RenderedQuery {\n const { dialect } = params;\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"postgresPhysicalCatalog\" });\n const collector = new ParamCollector(dialect);\n const namespace = collector.add(params.namespace);\n const extensionOwnedFilter = `NOT EXISTS (SELECT 1 FROM pg_catalog.pg_depend d JOIN pg_catalog.pg_class c ON c.oid = d.objid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE d.classid = 'pg_class'::regclass AND d.deptype = 'e' AND n.nspname = ${namespace} AND c.relname = table_name)`;\n let text: string;\n switch (params.query) {\n case \"tables\": text = `SELECT table_name FROM information_schema.tables WHERE table_schema = ${namespace} AND table_type = 'BASE TABLE' AND table_name <> '_vibe_migrations' AND ${extensionOwnedFilter} ORDER BY table_name`; break;\n case \"views\": text = `SELECT table_name FROM information_schema.views WHERE table_schema = ${namespace} AND ${extensionOwnedFilter} ORDER BY table_name`; break;\n case \"columns\": text = `SELECT table_name, column_name, data_type, udt_name, udt_schema, is_nullable, is_identity, is_generated, collation_name, column_default, datetime_precision, character_maximum_length, numeric_precision, numeric_scale, ordinal_position, catalog.full_type, catalog.generated_kind, catalog.generation_expression FROM information_schema.columns AS columns LEFT JOIN LATERAL (SELECT pg_catalog.format_type(a.atttypid, a.atttypmod) AS full_type, a.attgenerated::text AS generated_kind, CASE WHEN a.attgenerated <> '' THEN pg_catalog.pg_get_expr(d.adbin, d.adrelid, false) ELSE NULL END AS generation_expression FROM pg_catalog.pg_attribute a JOIN pg_catalog.pg_class c ON c.oid = a.attrelid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace LEFT JOIN pg_catalog.pg_attrdef d ON d.adrelid = a.attrelid AND d.adnum = a.attnum WHERE n.nspname = ${namespace} AND c.relname = columns.table_name AND a.attname = columns.column_name AND a.attnum > 0 AND NOT a.attisdropped) catalog ON true WHERE table_schema = ${namespace} ORDER BY table_name, ordinal_position`; break;\n case \"constraints\": text = `SELECT c.conname AS constraint_name, CASE c.contype WHEN 'p' THEN 'PRIMARY KEY' ELSE 'UNIQUE' END AS constraint_type, cl.relname AS table_name, att.attname AS column_name FROM pg_catalog.pg_constraint c JOIN pg_catalog.pg_class cl ON cl.oid = c.conrelid JOIN pg_catalog.pg_namespace n ON n.oid = cl.relnamespace JOIN unnest(c.conkey) WITH ORDINALITY AS k(attnum, ord) ON true JOIN pg_catalog.pg_attribute att ON att.attrelid = c.conrelid AND att.attnum = k.attnum WHERE c.contype IN ('p', 'u') AND n.nspname = ${namespace} ORDER BY cl.relname, c.conname, k.ord`; break;\n case \"checks\": text = `SELECT cl.relname AS table_name, c.conname AS constraint_name, pg_get_constraintdef(c.oid) AS definition FROM pg_catalog.pg_constraint c JOIN pg_catalog.pg_class cl ON cl.oid = c.conrelid JOIN pg_catalog.pg_namespace n ON n.oid = cl.relnamespace WHERE c.contype = 'c' AND n.nspname = ${namespace} ORDER BY cl.relname, c.conname`; break;\n case \"foreignKeys\": text = `SELECT c.conname AS constraint_name, cl.relname AS table_name, att.attname AS column_name, fn.nspname AS foreign_namespace, fcl.relname AS foreign_table_name, fatt.attname AS foreign_column_name, c.confdeltype AS on_delete_char, c.confupdtype AS on_update_char, c.convalidated AS validated, c.condeferrable AS deferrable, (SELECT bool_and(t.tgenabled IN ('O', 'A')) FROM pg_catalog.pg_trigger t WHERE t.tgconstraint = c.oid) AS triggers_enabled FROM pg_catalog.pg_constraint c JOIN pg_catalog.pg_class cl ON cl.oid = c.conrelid JOIN pg_catalog.pg_namespace n ON n.oid = cl.relnamespace JOIN pg_catalog.pg_class fcl ON fcl.oid = c.confrelid JOIN pg_catalog.pg_namespace fn ON fn.oid = fcl.relnamespace JOIN unnest(c.conkey) WITH ORDINALITY AS lk(attnum, ord) ON true JOIN unnest(c.confkey) WITH ORDINALITY AS rk(attnum, ord) ON lk.ord = rk.ord JOIN pg_catalog.pg_attribute att ON att.attrelid = c.conrelid AND att.attnum = lk.attnum JOIN pg_catalog.pg_attribute fatt ON fatt.attrelid = c.confrelid AND fatt.attnum = rk.attnum WHERE c.contype = 'f' AND n.nspname = ${namespace} ORDER BY cl.relname, c.conname, lk.ord`; break;\n case \"enums\": text = `SELECT t.typname AS type_name, n.nspname AS type_namespace, e.enumlabel AS enum_value, e.enumsortorder AS sort_order FROM pg_type t JOIN pg_enum e ON t.oid = e.enumtypid JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = ${namespace} AND NOT EXISTS (SELECT 1 FROM pg_catalog.pg_depend d WHERE d.classid = 'pg_type'::regclass AND d.objid = t.oid AND d.deptype = 'e') ORDER BY t.typname, e.enumsortorder`; break;\n case \"indexes\": text = `SELECT tablename AS table_name, indexname AS index_name, indexdef AS index_def, con.conname AS backing_constraint, con.contype AS backing_constraint_type, health.indisvalid AS valid, health.indisready AS ready, health.indimmediate AS immediate, health.indexprs IS NULL AS plain_columns, health.indnkeyatts AS key_count, health.indnatts AS attribute_count FROM pg_indexes ix JOIN pg_catalog.pg_namespace ns ON ns.nspname = ix.schemaname JOIN pg_catalog.pg_class idx ON idx.relnamespace = ns.oid AND idx.relname = ix.indexname JOIN pg_catalog.pg_index health ON health.indexrelid = idx.oid LEFT JOIN pg_catalog.pg_constraint con ON con.conindid = idx.oid AND con.contype IN ('p', 'u', 'x') WHERE schemaname = ${namespace} ORDER BY tablename, indexname`; break;\n }\n return { text, values: collector.values, returning: \"none\" };\n}\n",
19
- "import type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport { unsupportedCapability } from \"@vibeorm/schema\";\n\n/**\n * Turn JIT compilation off for the rest of the current transaction and return\n * the previous `jit` value as `previous` (read before the change). The bulk\n * index-key read costs far above `jit_above_cost`, and compiling it takes longer\n * than running it. Transaction-local: outside a transaction block it changes nothing.\n */\nexport function renderPostgresJitSuspend(params: { dialect: SqlDialect }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"indexOperatorClasses\" });\n return { text: \"SELECT setting.previous, pg_catalog.set_config('jit', 'off', true) AS current FROM (SELECT pg_catalog.current_setting('jit') AS previous OFFSET 0) setting\", values: [], returning: \"none\" };\n}\n\n/** Restore the transaction's `jit` value read by {@link renderPostgresJitSuspend}. */\nexport function renderPostgresJitRestore(params: { dialect: SqlDialect; previous: string }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"indexOperatorClasses\" });\n const collector = new ParamCollector(params.dialect);\n return { text: `SELECT pg_catalog.set_config('jit', ${collector.add(params.previous)}, true) AS current`, values: collector.values, returning: \"none\" };\n}\n\n/** Physical operands and unambiguous server-default evidence for actual type/access-method pairs. */\nexport function renderPostgresIndexKeys(params: { dialect: SqlDialect; table?: QualifiedSqlName; namespaces?: readonly string[]; expressionMetadata?: boolean }): RenderedQuery {\n const { dialect } = params;\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"indexOperatorClasses\" });\n const collector = new ParamCollector(dialect);\n const scope = params.table !== undefined\n ? `${params.expressionMetadata && params.table.namespace === \"pg_temp\" ? \"n.oid = pg_catalog.pg_my_temp_schema()\" : `n.nspname = ${collector.add(params.table.namespace)}`} AND c.relname = ${collector.add(params.table.name)}`\n : params.namespaces === undefined\n ? \"n.nspname <> 'information_schema' AND n.nspname NOT LIKE 'pg\\\\_%' ESCAPE '\\\\'\"\n : params.namespaces.length === 0 ? \"false\" : `n.nspname IN (${[...new Set(params.namespaces)].map((namespace) => collector.add(namespace)).join(\", \")})`;\n const defaultResolution = `LEFT JOIN LATERAL (WITH RECURSIVE input_types AS (SELECT t.oid, t.typbasetype, t.typtype, t.typelem, t.typcategory FROM pg_catalog.pg_type t WHERE t.oid = ${params.expressionMetadata ? \"key_attribute.atttypid\" : \"a.atttypid\"} UNION ALL SELECT t.oid, t.typbasetype, t.typtype, t.typelem, t.typcategory FROM pg_catalog.pg_type t JOIN input_types previous ON t.oid = previous.typbasetype WHERE previous.typtype = 'd'), candidates AS (SELECT candidate.oid, CASE WHEN candidate.opcintype = input.oid THEN 0 WHEN class_input.typispreferred AND class_input.typcategory = input.typcategory THEN 1 ELSE 2 END AS priority FROM pg_catalog.pg_opclass candidate JOIN pg_catalog.pg_type class_input ON class_input.oid = candidate.opcintype CROSS JOIN input_types input WHERE input.typtype <> 'd' AND candidate.opcdefault AND candidate.opcmethod = idx.relam AND (candidate.opcintype = input.oid OR EXISTS (SELECT 1 FROM pg_catalog.pg_cast cast_entry WHERE cast_entry.castsource = input.oid AND cast_entry.casttarget = candidate.opcintype AND cast_entry.castmethod = 'b' AND cast_entry.castcontext = 'i') OR input.typtype = 'e' AND candidate.opcintype = 'pg_catalog.anyenum'::regtype OR input.typelem <> 0 AND candidate.opcintype = 'pg_catalog.anyarray'::regtype)) SELECT (array_agg(candidate.oid))[1] AS oid FROM candidates candidate WHERE candidate.priority = (SELECT min(priority) FROM candidates) HAVING count(*) = 1) resolved_default ON true`;\n const expressionColumns = params.expressionMetadata ? `, CASE WHEN k.attnum = 0 THEN pg_catalog.pg_get_indexdef(i.indexrelid, k.ordinality::integer, false) ELSE NULL END AS expression, pg_catalog.pg_get_indexdef(i.indexrelid, 0, false) AS index_definition, pg_catalog.format_type(key_attribute.atttypid, key_attribute.atttypmod) AS result_type, (i.indoption[k.ordinality - 1] & 2) <> 0 AS nulls_first, ((i.indoption[k.ordinality - 1] & 2) <> 0) = ((i.indoption[k.ordinality - 1] & 1) <> 0) AS default_null_order, i.indcollation[k.ordinality - 1] AS collation_oid, CASE WHEN k.attnum = 0 THEN NULL ELSE i.indcollation[k.ordinality - 1] = a.attcollation END AS default_collation, i.indisvalid AS valid, i.indisready AS ready, i.indimmediate AS immediate, i.indnkeyatts AS key_count, i.indnatts AS attribute_count` : \"\";\n const expressionJoins = params.expressionMetadata ? ` JOIN pg_catalog.pg_attribute key_attribute ON key_attribute.attrelid = idx.oid AND key_attribute.attnum = k.ordinality` : \"\";\n return {\n text: `SELECT n.nspname AS table_namespace, c.relname AS table_name, idx.relname AS index_name, am.amname AS method, i.indisunique AS unique, pg_catalog.pg_get_expr(i.indpred, i.indrelid, false) AS predicate, i.indnullsnotdistinct AS nulls_not_distinct, k.ordinality AS ordinal, a.attname AS column_name, (i.indoption[k.ordinality - 1] & 1) <> 0 AS descending, opn.nspname AS operator_namespace, op.opcname AS operator_name, COALESCE(op.oid = resolved_default.oid, false) AS exact_default${expressionColumns} FROM pg_catalog.pg_index i JOIN pg_catalog.pg_class c ON c.oid = i.indrelid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace JOIN pg_catalog.pg_class idx ON idx.oid = i.indexrelid JOIN pg_catalog.pg_am am ON am.oid = idx.relam CROSS JOIN LATERAL unnest(i.indkey) WITH ORDINALITY k(attnum, ordinality) LEFT JOIN pg_catalog.pg_attribute a ON a.attrelid = c.oid AND a.attnum = k.attnum${expressionJoins} JOIN pg_catalog.pg_opclass op ON op.oid = i.indclass[k.ordinality - 1] JOIN pg_catalog.pg_namespace opn ON opn.oid = op.opcnamespace ${defaultResolution} WHERE ${scope} AND k.ordinality <= i.indnkeyatts ORDER BY n.nspname, c.relname, idx.relname, k.ordinality`,\n values: collector.values,\n returning: \"none\",\n };\n}\n",
19
+ "import type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport { unsupportedCapability } from \"@vibeorm/schema\";\n\n/**\n * Turn JIT compilation off for the rest of the current transaction and return\n * the previous `jit` value as `previous` (read before the change). The bulk\n * index-key read costs far above `jit_above_cost`, and compiling it takes longer\n * than running it. Transaction-local: outside a transaction block it changes nothing.\n */\nexport function renderPostgresJitSuspend(params: { dialect: SqlDialect }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"indexOperatorClasses\" });\n return { text: \"SELECT setting.previous, pg_catalog.set_config('jit', 'off', true) AS current FROM (SELECT pg_catalog.current_setting('jit') AS previous OFFSET 0) setting\", values: [], returning: \"none\" };\n}\n\n/** Restore the transaction's `jit` value read by {@link renderPostgresJitSuspend}. */\nexport function renderPostgresJitRestore(params: { dialect: SqlDialect; previous: string }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"indexOperatorClasses\" });\n const collector = new ParamCollector(params.dialect);\n return { text: `SELECT pg_catalog.set_config('jit', ${collector.add(params.previous)}, true) AS current`, values: collector.values, returning: \"none\" };\n}\n\n/** Physical operands and unambiguous server-default evidence for actual type/access-method pairs. */\nexport function renderPostgresIndexKeys(params: { dialect: SqlDialect; table?: QualifiedSqlName; namespaces?: readonly string[]; expressionMetadata?: boolean }): RenderedQuery {\n const { dialect } = params;\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"indexOperatorClasses\" });\n const collector = new ParamCollector(dialect);\n const scope = params.table !== undefined\n ? `${params.expressionMetadata && params.table.namespace === \"pg_temp\" ? \"n.oid = pg_catalog.pg_my_temp_schema()\" : `n.nspname = ${collector.add(params.table.namespace)}`} AND c.relname = ${collector.add(params.table.name)}`\n : params.namespaces === undefined\n ? \"n.nspname <> 'information_schema' AND n.nspname NOT LIKE 'pg\\\\_%' ESCAPE '\\\\'\"\n : params.namespaces.length === 0 ? \"false\" : `n.nspname IN (${[...new Set(params.namespaces)].map((namespace) => collector.add(namespace)).join(\", \")})`;\n // The default class is resolved for the key's INPUT type: the table column's type for a column key. The index\n // attribute stores the class's key type instead (text for GIN jsonb_ops, the element type for array_ops), so it is\n // read only for an expression key, where no table column exists (`a.atttypid` is NULL).\n const defaultResolution = `LEFT JOIN LATERAL (WITH RECURSIVE input_types AS (SELECT t.oid, t.typbasetype, t.typtype, t.typelem, t.typcategory FROM pg_catalog.pg_type t WHERE t.oid = ${params.expressionMetadata ? \"COALESCE(a.atttypid, key_attribute.atttypid)\" : \"a.atttypid\"} UNION ALL SELECT t.oid, t.typbasetype, t.typtype, t.typelem, t.typcategory FROM pg_catalog.pg_type t JOIN input_types previous ON t.oid = previous.typbasetype WHERE previous.typtype = 'd'), candidates AS (SELECT candidate.oid, CASE WHEN candidate.opcintype = input.oid THEN 0 WHEN class_input.typispreferred AND class_input.typcategory = input.typcategory THEN 1 ELSE 2 END AS priority FROM pg_catalog.pg_opclass candidate JOIN pg_catalog.pg_type class_input ON class_input.oid = candidate.opcintype CROSS JOIN input_types input WHERE input.typtype <> 'd' AND candidate.opcdefault AND candidate.opcmethod = idx.relam AND (candidate.opcintype = input.oid OR EXISTS (SELECT 1 FROM pg_catalog.pg_cast cast_entry WHERE cast_entry.castsource = input.oid AND cast_entry.casttarget = candidate.opcintype AND cast_entry.castmethod = 'b' AND cast_entry.castcontext = 'i') OR input.typtype = 'e' AND candidate.opcintype = 'pg_catalog.anyenum'::regtype OR input.typelem <> 0 AND candidate.opcintype = 'pg_catalog.anyarray'::regtype)) SELECT (array_agg(candidate.oid))[1] AS oid FROM candidates candidate WHERE candidate.priority = (SELECT min(priority) FROM candidates) HAVING count(*) = 1) resolved_default ON true`;\n const expressionColumns = params.expressionMetadata ? `, CASE WHEN k.attnum = 0 THEN pg_catalog.pg_get_indexdef(i.indexrelid, k.ordinality::integer, false) ELSE NULL END AS expression, pg_catalog.pg_get_indexdef(i.indexrelid, 0, false) AS index_definition, pg_catalog.format_type(key_attribute.atttypid, key_attribute.atttypmod) AS result_type, (i.indoption[k.ordinality - 1] & 2) <> 0 AS nulls_first, ((i.indoption[k.ordinality - 1] & 2) <> 0) = ((i.indoption[k.ordinality - 1] & 1) <> 0) AS default_null_order, i.indcollation[k.ordinality - 1] AS collation_oid, CASE WHEN k.attnum = 0 THEN NULL ELSE i.indcollation[k.ordinality - 1] = a.attcollation END AS default_collation, i.indisvalid AS valid, i.indisready AS ready, i.indimmediate AS immediate, i.indnkeyatts AS key_count, i.indnatts AS attribute_count` : \"\";\n const expressionJoins = params.expressionMetadata ? ` JOIN pg_catalog.pg_attribute key_attribute ON key_attribute.attrelid = idx.oid AND key_attribute.attnum = k.ordinality` : \"\";\n return {\n text: `SELECT n.nspname AS table_namespace, c.relname AS table_name, idx.relname AS index_name, am.amname AS method, i.indisunique AS unique, pg_catalog.pg_get_expr(i.indpred, i.indrelid, false) AS predicate, i.indnullsnotdistinct AS nulls_not_distinct, k.ordinality AS ordinal, a.attname AS column_name, (i.indoption[k.ordinality - 1] & 1) <> 0 AS descending, opn.nspname AS operator_namespace, op.opcname AS operator_name, COALESCE(op.oid = resolved_default.oid, false) AS exact_default${expressionColumns} FROM pg_catalog.pg_index i JOIN pg_catalog.pg_class c ON c.oid = i.indrelid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace JOIN pg_catalog.pg_class idx ON idx.oid = i.indexrelid JOIN pg_catalog.pg_am am ON am.oid = idx.relam CROSS JOIN LATERAL unnest(i.indkey) WITH ORDINALITY k(attnum, ordinality) LEFT JOIN pg_catalog.pg_attribute a ON a.attrelid = c.oid AND a.attnum = k.attnum${expressionJoins} JOIN pg_catalog.pg_opclass op ON op.oid = i.indclass[k.ordinality - 1] JOIN pg_catalog.pg_namespace opn ON opn.oid = op.opcnamespace ${defaultResolution} WHERE ${scope} AND k.ordinality <= i.indnkeyatts ORDER BY n.nspname, c.relname, idx.relname, k.ordinality`,\n values: collector.values,\n returning: \"none\",\n };\n}\n",
20
20
  "import { VibeError, isSqlObjectIdentity, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\n\n/** One physical migration index key, with an optional qualified PostgreSQL operator class. */\nexport type IndexColumnOperand = {\n readonly name: string;\n readonly desc?: boolean;\n readonly operatorClass?: QualifiedSqlName;\n};\n\n/** Render safe column operands; operator classes are a non-unique PostgreSQL capability. */\nexport function renderIndexColumns(params: {\n dialect: SqlDialect;\n columns: readonly IndexColumnOperand[];\n unique: boolean;\n}): string[] {\n const { dialect, columns, unique } = params;\n const hasOperatorClass = columns.some((column) => column.operatorClass !== undefined);\n if (hasOperatorClass && !dialect.capabilities.indexOperatorClasses) throw unsupportedCapability({ dialect: dialect.name, feature: \"indexOperatorClasses\" });\n if (hasOperatorClass && unique) throw unsupportedCapability({ dialect: dialect.name, feature: \"uniqueIndexOperatorClasses\", hint: \"custom unique operator classes can change client selector equality\" });\n return columns.map((column) => {\n const operatorClass = column.operatorClass;\n if (operatorClass !== undefined && !isSqlObjectIdentity({ kind: \"table\", name: operatorClass })) {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: \"Index operator class must be a qualified SQL name { namespace, name }\", meta: { rule: \"index-operator-class-identity\", column: column.name } });\n }\n const ops = operatorClass === undefined ? \"\" : ` ${dialect.quoteIdent({ name: operatorClass.namespace })}.${dialect.quoteIdent({ name: operatorClass.name })}`;\n return `${dialect.quoteIdent({ name: column.name })}${ops}${column.desc ? \" DESC\" : \"\"}`;\n });\n}\n",
21
21
  "import { VibeError, indexKeyDefinitionKey, indexKeyTerms, isExpressionIndex, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { Dialect, EnumIR, IndexIR, QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { renderIndexColumns } from \"./index-columns.ts\";\nimport { renderSchemaExpression } from \"./predicate.ts\";\nimport type { PredicateModel } from \"./predicate.ts\";\nimport type { RenderedQuery } from \"./render.ts\";\nimport { extractPostgresIndexKeys, renderPostgresIndexExpressionProbe } from \"./dialects/postgres-index-expressions.ts\";\nimport { assertMysqlIndexKeyStorage, extractMysqlIndexKeys, renderMysqlIndexExpressionProbe } from \"./dialects/mysql-index-expressions.ts\";\nimport { extractSqliteIndexKeys } from \"./dialects/sqlite-index-expressions.ts\";\n\n/** Complete ordered physical keys; expression text has no key wrapper or direction. */\nexport type IndexKeyOperand =\n | { readonly kind: \"field\"; readonly name: string; readonly desc: boolean; readonly decimal?: boolean; readonly operatorClass?: QualifiedSqlName }\n | { readonly kind: \"expression\"; readonly text: string; readonly desc: boolean };\n\n/** Scratch statements only: sessions, normalization context and cleanup belong to migrate. */\nexport type IndexExpressionProbeParams = {\n readonly dialect: SqlDialect;\n readonly operation: \"context\" | \"clone\" | \"createIndex\" | \"read\" | \"drop\";\n readonly probe: { readonly table: string; readonly index: string };\n readonly table?: QualifiedSqlName;\n readonly keys?: readonly IndexKeyOperand[];\n readonly unique?: boolean;\n readonly definition?: string;\n readonly backslashEscapes?: boolean;\n readonly where?: string;\n readonly nullsNotDistinct?: boolean;\n};\n\n/** Resolve logical terms using the shared scalar renderer, then qualify physical key storage. */\nexport function resolveIndexKeys({ index, model, dialect, enums = [], site }: {\n readonly index: IndexIR;\n readonly model: PredicateModel;\n readonly dialect: SqlDialect;\n readonly enums?: readonly EnumIR[];\n readonly site: string;\n}): readonly IndexKeyOperand[] {\n const computed = isExpressionIndex({ index });\n if (computed) indexKeyDefinitionKey({ index, model });\n const terms = indexKeyTerms({ index });\n if (computed && index.where !== undefined && !dialect.capabilities.partialIndexes) throw unsupportedCapability({ dialect: dialect.name, feature: \"partialIndexes\" });\n if (computed && index.nullsNotDistinct === true && dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"nullsNotDistinct\" });\n if (computed && !dialect.capabilities.expressionIndexes) throw unsupportedCapability({ dialect: dialect.name, feature: \"expressionIndexes\" });\n if (computed && (index.fields.length !== 0 || !terms.some((term) => term.kind !== \"field\"))) throw invalid({ site, reason: \"index-expression-terms\" });\n if (terms.length === 0) throw invalid({ site, reason: \"index-empty-keys\" });\n if (computed && (index.clientName !== undefined || index.constraintName !== undefined)) throw invalid({ site, reason: \"index-expression-selector\" });\n if (computed && (index.kind !== \"btree\" && index.kind !== \"unique\" || terms.some((term) => term.kind === \"field\" && term.field.operatorClass !== undefined))) throw unsupportedCapability({ dialect: dialect.name, feature: \"expressionIndexOperatorClasses\" });\n const keys = terms.map((term): IndexKeyOperand => {\n if (term.kind === \"field\") {\n const field = model.fields.find((candidate) => candidate.name === term.field.name);\n if (field === undefined) throw invalid({ site, reason: \"index-unknown-field\" });\n return { kind: \"field\", name: field.dbName ?? field.name, desc: term.field.sort === \"desc\", ...(dialect.name === \"sqlite\" && field.type === \"Decimal\" ? { decimal: true } : {}), ...(term.field.operatorClass === undefined ? {} : { operatorClass: term.field.operatorClass }) };\n }\n if (term.kind === \"raw\") {\n if (index.name === undefined || typeof term.sql !== \"string\" || !term.sql.trim() || term.sql.includes(\"\\0\")) throw invalid({ site, reason: \"index-raw-expression\" });\n return { kind: \"expression\", text: term.sql, desc: term.sort === \"desc\" };\n }\n const rendered = renderSchemaExpression({ expression: term.expression, model, dialect, enums, usage: \"indexExpression\", site });\n if (![\"lower\", \"upper\", \"add\", \"sub\", \"mul\"].includes(term.expression.kind)) throw invalid({ site, reason: \"index-expression-root\" });\n if (rendered.resultType.refinement !== undefined || typeof rendered.resultType.type !== \"string\" || ![\"String\", \"Int\", \"BigInt\", \"Float\", \"Decimal\"].includes(rendered.resultType.type)) throw invalid({ site, reason: \"index-expression-result\" });\n return { kind: \"expression\", text: rendered.text, desc: term.sort === \"desc\" };\n });\n if (computed && dialect.name === \"mysql\") assertMysqlIndexKeyStorage({ dialect, model, terms });\n return keys;\n}\n\n/** Render complete key fragments; the caller owns the outer CREATE/ALTER list. */\nexport function renderIndexKeys({ dialect, keys, unique }: {\n readonly dialect: SqlDialect;\n readonly keys: readonly IndexKeyOperand[];\n readonly unique: boolean;\n}): readonly string[] {\n if (keys.length === 0) throw invalid({ site: \"index\", reason: \"index-empty-keys\" });\n const computed = keys.some((key) => key.kind === \"expression\");\n if (computed && !dialect.capabilities.expressionIndexes) throw unsupportedCapability({ dialect: dialect.name, feature: \"expressionIndexes\" });\n if (computed && keys.some((key) => key.kind === \"field\" && key.operatorClass !== undefined)) throw unsupportedCapability({ dialect: dialect.name, feature: \"expressionIndexOperatorClasses\" });\n return keys.map((key) => {\n if (key.kind === \"field\") {\n if (dialect.name === \"sqlite\" && key.decimal === true) return `CAST(${dialect.quoteIdent({ name: key.name })} AS REAL)${key.desc ? \" DESC\" : \"\"}`;\n return renderIndexColumns({ dialect, columns: [key], unique })[0]!;\n }\n if (!key.text.trim() || key.text.includes(\"\\0\")) throw invalid({ site: \"index\", reason: \"index-raw-expression\" });\n const expression = dialect.name === \"sqlite\" ? key.text : `(${key.text})`;\n return `${expression}${key.desc ? \" DESC\" : \"\"}`;\n });\n}\n\n/** Recover raw physical terms without inventing typed logical expressions or Decimal origin. */\nexport function extractIndexKeys({ dialect, definition, index, backslashEscapes = true }: {\n readonly dialect: Dialect;\n readonly definition: string;\n readonly index: string;\n readonly backslashEscapes?: boolean;\n}): readonly IndexKeyOperand[] | undefined {\n switch (dialect) {\n case \"postgres\": return extractPostgresIndexKeys({ definition, index });\n case \"sqlite\": return extractSqliteIndexKeys({ definition, index });\n case \"mysql\": return extractMysqlIndexKeys({ definition, index, backslashEscapes });\n }\n}\n\n/** Render a real expression-index normalization host, never a scalar CHECK surrogate. */\nexport function renderIndexExpressionProbe({ ...params }: IndexExpressionProbeParams): readonly RenderedQuery[] {\n if (params.operation === \"context\" && params.dialect.name === \"sqlite\") return [{ text: \"SELECT sqlite_version() AS version\", values: [], returning: \"none\" }];\n if (!params.dialect.capabilities.expressionIndexes) throw unsupportedCapability({ dialect: params.dialect.name, feature: \"expressionIndexes\" });\n switch (params.dialect.name) {\n case \"postgres\": return renderPostgresIndexExpressionProbe(params);\n case \"mysql\": return renderMysqlIndexExpressionProbe(params);\n case \"sqlite\": throw unsupportedCapability({ dialect: \"sqlite\", feature: \"indexExpressionNormalizationProbe\", hint: \"SQLite expression indexes use quote-aware source extraction, not a normalization probe\" });\n }\n}\n\n/** Version admission after a connection reveals its host, before scratch or user index DDL. */\nexport function assertIndexExpressionVersion({ dialect, version }: {\n readonly dialect: Dialect;\n readonly version: string;\n}): void {\n if (dialect === \"postgres\") return;\n const match = version.match(/^(\\d+)\\.(\\d+)\\.(\\d+)(?:[-\\s].*)?$/);\n const parts = match?.slice(1, 4).map(Number);\n const minimum = dialect === \"mysql\" ? [8, 0, 13] : [3, 9, 0];\n const admitted = parts !== undefined && !/mariadb/i.test(version) && parts.some((part, ordinal) => part > minimum[ordinal]! && parts.slice(0, ordinal).every((prefix, position) => prefix === minimum[position])) || parts !== undefined && parts.every((part, ordinal) => part === minimum[ordinal]);\n if (!admitted) throw unsupportedCapability({ dialect, feature: \"expressionIndexServerVersion\", hint: `Expression indexes require a known ${dialect} version at least ${minimum.join(\".\")}; received ${JSON.stringify(version)}` });\n}\n\nfunction invalid({ site, reason }: { readonly site: string; readonly reason: string }): VibeError {\n return new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: `Invalid index keys at ${site}: ${reason}`, meta: { rule: reason, site } });\n}\n",
22
22
  "/**\n * Typed schema predicates → SQL text.\n *\n * The ONE place a `PredicateIR` becomes SQL, for both of the sites that cannot\n * carry a bound parameter: a CHECK constraint body and a partial index's\n * `WHERE`. Constitution rule 4 — every SQL-text decision lives in a dialect\n * here, never in migrate, the DSL or a query builder.\n *\n * Shared scalar rendering also serves expression-index keys. The caller owns\n * expression-index DDL and its additional database-object qualification.\n *\n * What it guarantees:\n *\n * - **Logical field names resolve to physical columns.** `@map(\"qty_total\")`\n * is applied here, so renaming a mapped column cannot leave a CHECK naming a\n * column that no longer exists.\n * - **Identifiers are quoted through `dialect.quoteIdent`, literals through\n * `dialect.quoteStringLiteral`.** No value the author writes can escape its\n * literal and become SQL structure.\n * - **Operand scalars must match the expression result type.** Local dates keep\n * their distinct logical identity, shared with foreign-key pairing.\n * - **A dialect that cannot express something refuses here**, at the earliest\n * knowable moment (generate time), with a `VibeError` carrying a stable\n * `meta.rule` — never silently different SQL.\n *\n * Three-valued logic is NOT smoothed over. A comparison against NULL is\n * UNKNOWN, and a CHECK passes on TRUE **or** UNKNOWN, so nothing here inserts\n * an implicit `IS NOT NULL` guard. An author who wants all-or-none writes it\n * with `isNull`/`isNotNull`.\n */\n\nimport { VibeError, assertPredicateCapabilities, fieldTypeIdentity, isCanonicalLocalDate, isEnumType, isLocalDateField, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { EnumIR, FieldIR, ModelIR, PredicateBooleanUsage, PredicateExpression, PredicateIR, PredicateNumericType, PredicateOperand, PredicateResultType, PredicateUsage as SchemaPredicateUsage, PredicateValue } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\n\n// ─── Public API ───────────────────────────────────────────────────\n\n/**\n * Where a Boolean predicate is being rendered. Each host has different database\n * limits; scalar index-expression usage is handled by renderSchemaExpression.\n */\nexport type PredicateUsage = PredicateBooleanUsage;\n\n/**\n * The part of a model a predicate reads: its name (for error messages) and its\n * fields (for physical column names and scalar types). Narrow on purpose — a\n * predicate can never depend on relations, indexes or view-ness.\n */\nexport type PredicateModel = Pick<ModelIR, \"name\" | \"fields\">;\n\n/** Render a typed predicate as the SQL text of a CHECK body or an index `WHERE`. */\nexport function renderPredicate(params: {\n predicate: PredicateIR;\n model: PredicateModel;\n dialect: SqlDialect;\n /** Schema enums, for membership checking of enum operands. */\n enums?: readonly EnumIR[];\n usage: PredicateUsage;\n /** Human label naming the declaration, e.g. `CHECK \"order_total_nonnegative\"`. */\n site: string;\n}): string {\n assertPredicateCapabilities({ predicate: params.predicate, dialect: params.dialect.name, usage: params.usage, model: params.model });\n if (params.usage === \"exclusionPredicate\" && !params.dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: params.dialect.name, feature: \"exclusionConstraints\" });\n if (params.usage === \"indexPredicate\" && !params.dialect.capabilities.partialIndexes) {\n throw unsupportedCapability({ dialect: params.dialect.name, feature: \"partialIndexes\" });\n }\n const context: RenderContext = {\n model: params.model,\n dialect: params.dialect,\n enums: params.enums ?? [],\n usage: params.usage,\n site: params.site,\n };\n return renderNode({ node: params.predicate, context });\n}\n\n/** Render a scalar schema expression. Expression-index DDL and host qualification belong to the caller. */\nexport function renderSchemaExpression({ expression, model, dialect, enums = [], usage, site }: {\n expression: PredicateExpression;\n model: PredicateModel;\n dialect: SqlDialect;\n enums?: readonly EnumIR[];\n usage: \"indexExpression\";\n site: string;\n}): { readonly text: string; readonly resultType: PredicateResultType } {\n assertPredicateCapabilities({ expression, dialect: dialect.name, usage, model });\n const context: RenderContext = { model, dialect, enums, usage, site };\n const { text, resultType } = renderExpression({ expression, context });\n return { text, resultType };\n}\n\n// ─── Internals ────────────────────────────────────────────────────\n\ntype RenderContext = {\n readonly model: PredicateModel;\n readonly dialect: SqlDialect;\n readonly enums: readonly EnumIR[];\n readonly usage: SchemaPredicateUsage;\n readonly site: string;\n};\n\n/** Operator precedence, so the renderer emits the MINIMUM parentheses. */\nconst PRECEDENCE: Readonly<Record<PredicateIR[\"kind\"], number>> = {\n or: 1,\n and: 2,\n not: 3,\n compare: 4,\n inList: 4,\n isNull: 4,\n isTrue: 4,\n};\n\nconst COMPARISON_SQL: Readonly<Record<string, string>> = {\n eq: \"=\",\n ne: \"<>\",\n gt: \">\",\n gte: \">=\",\n lt: \"<\",\n lte: \"<=\",\n};\n\n/** Exact decimal integer, no exponent, no leading `+`. */\nconst EXACT_INTEGER: RegExp = /^-?(0|[1-9]\\d*)$/;\n/** Exact fixed-point decimal — the spelling `Decimal` columns store. */\nconst EXACT_DECIMAL: RegExp = /^-?(0|[1-9]\\d*)(\\.\\d+)?$/;\n\nconst INT32_MIN = -2_147_483_648n;\nconst INT32_MAX = 2_147_483_647n;\nconst INT64_MIN = -(2n ** 63n);\nconst INT64_MAX = 2n ** 63n - 1n;\n\nfunction refuse(params: {\n context: RenderContext;\n rule: string;\n message: string;\n meta?: Record<string, unknown>;\n}): never {\n const { context, rule, message } = params;\n throw new VibeError({\n code: \"VIBE_SCHEMA_INVALID\",\n message: `${context.site} on \"${context.model.name}\": ${message}`,\n meta: { rule, model: context.model.name, site: context.site, ...(params.meta ?? {}) },\n });\n}\n\n/** Wrap a child only when it binds LOOSER than its parent. */\nfunction renderChild(params: { node: PredicateIR; parent: PredicateIR[\"kind\"]; context: RenderContext }): string {\n const { node, parent, context } = params;\n // A singleton group emits its child, so its child's precedence is authoritative.\n if ((node.kind === \"and\" || node.kind === \"or\") && node.operands.length === 1) {\n return renderChild({ node: node.operands[0]!, parent, context });\n }\n const text = renderNode({ node, context });\n return PRECEDENCE[node.kind] < PRECEDENCE[parent] ? `(${text})` : text;\n}\n\nfunction renderNode(params: { node: PredicateIR; context: RenderContext }): string {\n const { node, context } = params;\n\n switch (node.kind) {\n case \"and\":\n case \"or\": {\n if (node.operands.length === 0) {\n refuse({\n context,\n rule: \"predicate-empty\",\n message: `${node.kind === \"and\" ? \"and()\" : \"or()\"} has no operands — an empty boolean group has no honest SQL spelling`,\n });\n }\n if (node.operands.length === 1) return renderNode({ node: node.operands[0]!, context });\n const separator = node.kind === \"and\" ? \" AND \" : \" OR \";\n return node.operands\n .map((operand) => renderChild({ node: operand, parent: node.kind, context }))\n .join(separator);\n }\n\n case \"not\":\n return `NOT ${renderChild({ node: node.operand, parent: \"not\", context })}`;\n\n case \"isTrue\":\n return `COALESCE(${renderNode({ node: node.operand, context })}, FALSE)`;\n\n case \"isNull\": {\n // No cast here, on any dialect: a cast of NULL is still NULL, and the\n // bare column keeps the predicate index-usable.\n const field = resolveField({ name: node.field.name, context, nullTest: true });\n return `${quoteColumn({ field, context })} IS ${node.negate === true ? \"NOT NULL\" : \"NULL\"}`;\n }\n\n case \"compare\": {\n const left = renderExpression({ expression: node.left, context });\n const right = renderOperand({ operand: node.right, left, context });\n return `${left.text} ${COMPARISON_SQL[node.op]} ${right}`;\n }\n\n case \"inList\": {\n if (node.values.length === 0) {\n refuse({\n context,\n rule: \"predicate-empty\",\n message: `inList(\"${node.field.name}\") has no values — an empty IN list is UNKNOWN on every row and never what an author means`,\n meta: { field: node.field.name },\n });\n }\n const field = resolveField({ name: node.field.name, context });\n const values = node.values\n .map((value) => renderLiteral({ value, resultType: fieldResultType({ field, context }), fieldName: field.name, context }))\n .join(\", \");\n return `${compareColumn({ field, context })} ${node.negate === true ? \"NOT IN\" : \"IN\"} (${values})`;\n }\n }\n}\n\n// ─── Fields and columns ───────────────────────────────────────────\n\n/** Resolve a LOGICAL field name to its `FieldIR`, refusing everything unusable. */\nfunction resolveField(params: { name: string; context: RenderContext; nullTest?: boolean }): FieldIR {\n const { name, context } = params;\n const field = context.model.fields.find((candidate) => candidate.name === name);\n\n if (field === undefined) {\n refuse({\n context,\n rule: \"predicate-unknown-field\",\n message: `references field \"${name}\", which the model does not declare`,\n meta: { field: name },\n });\n }\n if (field.isList) {\n refuse({\n context,\n rule: \"predicate-list-field\",\n message: `compares scalar list \"${name}\" — array operators differ per dialect; use a raw expression for them`,\n meta: { field: name },\n });\n }\n if (field.isUnsupported === true) {\n refuse({\n context,\n rule: \"predicate-unsupported-type\",\n message: `references \"${name}\", an Unsupported(\"${field.nativeType ?? \"?\"}\") column whose operators VibeORM does not model — use a raw expression`,\n meta: { field: name },\n });\n }\n if (params.nullTest !== true && (field.type === \"Json\" || field.type === \"Bytes\")) {\n refuse({\n context,\n rule: \"predicate-unsupported-type\",\n message: `references ${field.type} column \"${name}\" — ${field.type} comparison operators differ per dialect; use a raw expression`,\n meta: { field: name, type: field.type },\n });\n }\n // MySQL error 3818, reproduced on this project's mysql 8.4.11: \"Check\n // constraint 'x' cannot refer to an auto-increment column.\" Refusing while\n // generating beats emitting DDL the server rejects halfway through a\n // migration. Partial indexes never reach this — mysql has none at all.\n if (\n context.usage === \"check\" &&\n context.dialect.name === \"mysql\" &&\n field.default?.kind === \"autoincrement\"\n ) {\n throw unsupportedCapability({\n dialect: \"mysql\",\n feature: `CHECK constraint referencing auto-increment column \"${context.model.name}.${name}\"`,\n hint: \"mysql refuses this with error 3818 — enforce the rule in application code or on a non-generated column\",\n });\n }\n\n return field;\n}\n\n/** The physical, quoted column. */\nfunction quoteColumn(params: { field: FieldIR; context: RenderContext }): string {\n const { field, context } = params;\n return context.dialect.quoteIdent({ name: field.dbName ?? field.name });\n}\n\n/**\n * The column as it appears at a COMPARISON site.\n *\n * Identical to {@link quoteColumn} everywhere except sqlite Decimal: a Decimal\n * stores as exact TEXT there, so a bare comparison is lexicographic (`'9'` >\n * `'10'`). The runtime already compares those columns as `CAST(col AS REAL)`\n * (the B4 decision in `ast.ts`'s `ColRef.castReal`), and a CHECK that disagreed\n * with the query that reads the same column would be worse than either.\n */\nfunction compareColumn(params: { field: FieldIR; context: RenderContext }): string {\n const { field, context } = params;\n const quoted = quoteColumn({ field, context });\n return context.dialect.name === \"sqlite\" && field.type === \"Decimal\"\n ? `CAST(${quoted} AS REAL)`\n : quoted;\n}\n\n// ─── Operands ─────────────────────────────────────────────────────\n\ntype RenderedExpression = {\n readonly text: string;\n readonly resultType: PredicateResultType;\n /** Diagnostic provenance only. Never used as result storage metadata. */\n readonly fieldName: string;\n};\n\nfunction fieldResultType({ field, context }: { field: FieldIR; context: RenderContext }): PredicateResultType {\n if (isLocalDateField({ field })) return { type: field.type, refinement: \"localDate\" };\n if (context.dialect.name === \"postgres\" && field.type === \"String\" && field.nativeType?.trim().toLowerCase() === \"uuid\") return { type: \"String\", refinement: \"nativeUuid\" };\n return { type: field.type };\n}\n\nfunction resultIdentity({ resultType }: { resultType: PredicateResultType }): string {\n return resultType.refinement === \"localDate\" ? \"localDate\" : fieldTypeIdentity({ type: resultType.type });\n}\n\nconst ARITHMETIC_SQL: Readonly<Record<\"add\" | \"sub\" | \"mul\", string>> = {\n add: \"+\",\n sub: \"-\",\n mul: \"*\",\n};\n\n/** SQLite's native arithmetic seam. The family is supplied so any later overflow policy changes here only. */\nfunction renderSqliteArithmetic({ left, right, kind }: { left: string; right: string; kind: \"add\" | \"sub\" | \"mul\"; type: PredicateNumericType }): string {\n return `(${left} ${ARITHMETIC_SQL[kind]} ${right})`;\n}\n\nfunction renderExpression({ expression, context }: { expression: PredicateExpression; context: RenderContext }): RenderedExpression {\n switch (expression.kind) {\n case \"field\": {\n const field = resolveField({ name: expression.name, context });\n return { text: compareColumn({ field, context }), resultType: fieldResultType({ field, context }), fieldName: field.name };\n }\n case \"jsonText\": {\n const field = resolveField({ name: expression.field.name, context, nullTest: true });\n if (field.type !== \"Json\") refuse({ context, rule: \"predicate-type-mismatch\", message: `jsonText requires a scalar Json field, not \"${field.name}\"` });\n if (!Array.isArray(expression.path) || Array.from(expression.path).some((segment: unknown) => typeof segment !== \"string\" || segment.includes(\"\\u0000\"))) {\n refuse({ context, rule: \"predicate-json-path\", message: \"jsonText requires a string-only path without NUL bytes\" });\n }\n const path = expression.path.map((value) => context.dialect.quoteStringLiteral({ value })).join(\", \");\n return { text: `(${quoteColumn({ field, context })} #>> ARRAY[${path}]::text[])`, resultType: { type: \"String\" }, fieldName: field.name };\n }\n case \"length\":\n case \"lower\":\n case \"upper\": {\n const inner = renderExpression({ expression: expression.expression, context });\n if (inner.resultType.type !== \"String\" || inner.resultType.refinement === \"localDate\") {\n refuse({ context, rule: \"predicate-type-mismatch\", message: `${expression.kind} requires a text expression, not a local date or another scalar`, meta: { field: inner.fieldName } });\n }\n // PostgreSQL native types without lower()/upper() (Uuid, Inet, …) were refused by capability admission above.\n return { text: `${expression.kind}(${inner.text})`, resultType: { type: expression.kind === \"length\" ? \"Int\" : \"String\" }, fieldName: inner.fieldName };\n }\n case \"add\":\n case \"sub\":\n case \"mul\": {\n const left = renderExpression({ expression: expression.left, context });\n const type = left.resultType.type;\n if (type !== \"Int\" && type !== \"BigInt\" && type !== \"Float\" && type !== \"Decimal\") {\n refuse({ context, rule: \"predicate-type-mismatch\", message: `${expression.kind} requires Int, BigInt, Float or Decimal operands`, meta: { field: left.fieldName } });\n }\n const right = renderOperand({ operand: expression.right, left, context });\n // The admitted numeric families were checked by capability admission at the entry point (one source).\n const text = context.dialect.name === \"sqlite\"\n ? renderSqliteArithmetic({ left: left.text, right, kind: expression.kind, type })\n : `(${left.text} ${ARITHMETIC_SQL[expression.kind]} ${right})`;\n return { text, resultType: { type }, fieldName: left.fieldName };\n }\n }\n}\n\nfunction renderOperand({ operand, left, context }: {\n operand: PredicateOperand;\n left: RenderedExpression;\n context: RenderContext;\n}): string {\n if (operand.kind === \"value\") return renderLiteral({ value: operand, resultType: left.resultType, fieldName: left.fieldName, context });\n\n const other = renderExpression({ expression: operand, context });\n const leftType = resultIdentity({ resultType: left.resultType });\n const rightType = resultIdentity({ resultType: other.resultType });\n if (leftType !== rightType) {\n refuse({\n context,\n rule: \"predicate-type-mismatch\",\n message: `compares \"${left.fieldName}\" (${leftType}) with \"${other.fieldName}\" (${rightType}): both operands need the same scalar type`,\n meta: { field: left.fieldName, other: other.fieldName, fieldType: leftType, otherType: rightType },\n });\n }\n return other.text;\n}\n\n/** One literal, validated against the expression result and spelled for the dialect. */\nfunction renderLiteral(params: {\n value: PredicateValue;\n resultType: PredicateResultType;\n fieldName: string;\n context: RenderContext;\n}): string {\n const { resultType, fieldName, context } = params;\n const { value } = params.value;\n const type = resultType.type;\n\n const wrongCarrier = (expected: string): never =>\n refuse({\n context,\n rule: \"predicate-type-mismatch\",\n message: `compares ${fieldTypeIdentity({ type })} field \"${fieldName}\" with ${describe({ value })}: ${expected}`,\n meta: { field: fieldName, fieldType: fieldTypeIdentity({ type }), value },\n });\n\n if (isEnumType(type)) {\n if (typeof value !== \"string\") return wrongCarrier(`enum ${type.enum} takes one of its member names as a string`);\n const declared = context.enums.find((entry) => entry.name === type.enum);\n if (declared !== undefined && !declared.values.includes(value)) {\n refuse({\n context,\n rule: \"predicate-enum-member\",\n message: `compares \"${fieldName}\" with \"${value}\", which is not a member of enum ${type.enum} (${declared.values.join(\", \")})`,\n meta: { field: fieldName, enum: type.enum, value, members: [...declared.values] },\n });\n }\n return stringLiteral({ value, context, fieldName });\n }\n\n switch (type) {\n case \"String\":\n if (typeof value !== \"string\") return wrongCarrier(\"a String column takes a string literal\");\n if (resultType.refinement === \"localDate\" && !isCanonicalLocalDate({ value })) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares local-date field \"${fieldName}\" with a noncanonical or invalid calendar date`,\n meta: { field: fieldName, value },\n });\n }\n return stringLiteral({ value, context, fieldName });\n\n case \"Boolean\":\n if (typeof value !== \"boolean\") return wrongCarrier(\"a Boolean column takes `true` or `false`\");\n return value ? context.dialect.booleanLiteral.true : context.dialect.booleanLiteral.false;\n\n case \"Int\":\n return integerLiteral({ value, fieldName, context, min: INT32_MIN, max: INT32_MAX, label: \"Int\" });\n\n case \"BigInt\":\n return integerLiteral({ value, fieldName, context, min: INT64_MIN, max: INT64_MAX, label: \"BigInt\" });\n\n case \"Float\": {\n if (typeof value !== \"number\") return wrongCarrier(\"a Float column takes a number\");\n if (!Number.isFinite(value)) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with ${String(value)}: a Float literal must be finite`,\n meta: { field: fieldName, value: String(value) },\n });\n }\n return String(value);\n }\n\n case \"Decimal\": {\n // Exact decimal TEXT only, mirroring `dsl.decimal({ default: \"0.00\" })`.\n // A JS number cannot carry an exact decimal — `0.1 + 0.2` is the classic\n // proof — so accepting one here would silently move the boundary of the\n // author's rule.\n if (typeof value !== \"string\") {\n return wrongCarrier(\"a Decimal column takes exact decimal TEXT (\\\"0\\\", \\\"19.99\\\") — a JS number cannot carry an exact decimal\");\n }\n if (!EXACT_DECIMAL.test(value)) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with \"${value}\", which is not an exact decimal literal`,\n meta: { field: fieldName, value },\n });\n }\n return value;\n }\n\n case \"DateTime\":\n // Three correct spellings across the matrix (postgres `timestamp`, mysql\n // `DATETIME(3)` in UTC, sqlite ISO-8601 TEXT with an explicit `Z`), and\n // picking the wrong one is a silent data bug rather than an error. Every\n // consumer rule this expression language exists for compares two DateTime\n // COLUMNS (\"end after start\"), which needs no literal at all.\n refuse({\n context,\n rule: \"predicate-unsupported-literal\",\n message: `compares DateTime field \"${fieldName}\" with a literal. DateTime literals are spelled differently on postgres, mysql and sqlite, so VibeORM does not guess one. Compare two DateTime columns, or write a raw expression for a fixed instant`,\n meta: { field: fieldName },\n });\n\n case \"Json\":\n case \"Bytes\":\n // Unreachable: resolveField already refused these columns. Kept so the\n // switch stays exhaustive if ScalarType grows.\n return wrongCarrier(`${type} columns take no predicate literal`);\n }\n}\n\nfunction integerLiteral(params: {\n value: string | number | boolean;\n fieldName: string;\n context: RenderContext;\n min: bigint;\n max: bigint;\n label: string;\n}): string {\n const { value, fieldName, context, min, max, label } = params;\n\n let text: string;\n if (typeof value === \"number\") {\n if (!Number.isSafeInteger(value)) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with ${String(value)}: an ${label} literal must be an exact integer JavaScript can represent; pass a bigint or a decimal string for larger values`,\n meta: { field: fieldName, value: String(value) },\n });\n }\n text = String(value);\n } else if (typeof value === \"string\") {\n if (!EXACT_INTEGER.test(value)) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with \"${value}\", which is not an exact integer literal`,\n meta: { field: fieldName, value },\n });\n }\n text = value;\n } else {\n refuse({\n context,\n rule: \"predicate-type-mismatch\",\n message: `compares ${label} field \"${fieldName}\" with ${describe({ value })}: an ${label} column takes an integer`,\n meta: { field: fieldName, value },\n });\n }\n\n const parsed = BigInt(text);\n if (parsed < min || parsed > max) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with ${text}, which is outside the range an ${label} column can hold (${min}…${max})`,\n meta: { field: fieldName, value: text },\n });\n }\n return text;\n}\n\nfunction stringLiteral(params: { value: string; context: RenderContext; fieldName: string }): string {\n const { value, context, fieldName } = params;\n // A NUL byte terminates the string for the C-based client libraries every\n // driver here is built on, and postgres `text` cannot store one at all — so\n // it can never round-trip and must not reach DDL.\n if (value.includes(\"\\u0000\")) {\n refuse({\n context,\n rule: \"predicate-literal-invalid\",\n message: `compares \"${fieldName}\" with a string containing a NUL byte, which no dialect here can store`,\n meta: { field: fieldName },\n });\n }\n return context.dialect.quoteStringLiteral({ value });\n}\n\nfunction describe(params: { value: unknown }): string {\n const { value } = params;\n return typeof value === \"string\" ? `the string ${JSON.stringify(value)}` : `the ${typeof value} ${String(value)}`;\n}\n",
@@ -38,7 +38,7 @@
38
38
  "import { VibeError } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { snapshotSqlValue } from \"./parameter-snapshot.ts\";\nimport { ParamCollector } from \"./params.ts\";\nimport { registerSqlHandleCheck } from \"./sql-handles.ts\";\nimport { isSqlBindingCollector, recordSqlBinding, recordSqlBindingCheck, sqlParameterTransport } from \"./sql-bindings.ts\";\nimport { resultScalarContract } from \"./result-decoder.ts\";\nimport type { ResultDecoder } from \"./result-decoder.ts\";\n\ndeclare const fragmentBrand: unique symbol;\n/** Opaque executable SQL, constructed by sql, never by casting an object. */\nexport type SqlFragment = { readonly [fragmentBrand]: true };\n\ntype Part =\n | string\n | { readonly value: unknown; readonly decoder?: ResultDecoder<unknown> }\n | { readonly ident: readonly string[] }\n | { readonly row: \"existing\" | \"incoming\"; readonly column: string }\n | { readonly greatest: readonly SqlFragment[] };\nconst fragments = new WeakMap<object, readonly Part[]>();\nregisterSqlHandleCheck({ check: (value) => fragments.has(value) });\n\nfunction invalid(message: string): never {\n throw new VibeError({ code: \"VIBE_VALIDATION\", message });\n}\n\nfunction construct(parts: readonly Part[]): SqlFragment {\n const snapshot = Object.freeze([...parts]);\n const fragment = Object.freeze(Object.defineProperty(Object.create(null), \"toJSON\", {\n value: (): { parts: readonly Part[] } => ({ parts: snapshot }),\n })) as SqlFragment;\n fragments.set(fragment, snapshot);\n return fragment;\n}\n\n/** Runtime authenticity check; structural copies are not executable. */\nexport function isSqlFragment(value: unknown): value is SqlFragment {\n return typeof value === \"object\" && value !== null && fragments.has(value);\n}\n\nfunction partsOf(value: SqlFragment): readonly Part[] {\n return fragments.get(value) ?? invalid(\"Expected a constructed SQL fragment\");\n}\n\n/** Whether a fragment holds a greatest node (template interpolation flattens parts). */\nfunction containsGreatest(fragment: SqlFragment): boolean {\n return partsOf(fragment).some((part) => typeof part !== \"string\" && \"greatest\" in part);\n}\n\nfunction identifier(parts: readonly string[]): void {\n if (!Array.isArray(parts) || parts.length === 0 || parts.some((part) => typeof part !== \"string\" || part.length === 0 || part.includes(\"\\0\"))) {\n invalid(\"SQL identifiers require non-empty, NUL-free name components\");\n }\n}\n\n/** The public composition helpers. text is trusted SQL; interpolated strings are values. */\nexport type SqlTag = {\n (strings: TemplateStringsArray, ...values: readonly unknown[]): SqlFragment;\n readonly text: (params: { text: string }) => SqlFragment;\n readonly ident: (params: { parts: readonly string[] }) => SqlFragment;\n readonly value: <T>(params: { value: NoInfer<T>; decoder?: ResultDecoder<T> }) => SqlFragment;\n readonly join: (params: { items: readonly unknown[]; separator?: SqlFragment }) => SqlFragment;\n readonly existing: (params: { column: string }) => SqlFragment;\n readonly incoming: (params: { column: string }) => SqlFragment;\n /** Portable scalar maximum, with NULL ignored (all NULL produces NULL). */\n readonly greatest: (params: { values: readonly [SqlFragment, SqlFragment] }) => SqlFragment;\n};\n\nfunction template(strings: TemplateStringsArray, ...values: readonly unknown[]): SqlFragment {\n if (!Array.isArray(strings) || !Array.isArray(strings.raw) || strings.length !== values.length + 1 || strings.some((text) => typeof text !== \"string\")) {\n invalid(\"Use sql as a template tag\");\n }\n const parts: Part[] = [];\n for (let index = 0; index < strings.length; index++) {\n parts.push(strings[index]!);\n if (index < values.length) {\n const value = values[index];\n if (isSqlFragment(value)) parts.push(...partsOf(value));\n else parts.push(Object.freeze({ value: snapshotSqlValue(value) }));\n }\n }\n return construct(parts);\n}\n\n/** Compose SQL without parameter-offset arithmetic. */\nexport const sql: SqlTag = Object.freeze(Object.assign(template, {\n text: ({ text }: { text: string }): SqlFragment => {\n if (typeof text !== \"string\" || text.includes(\"\\0\")) invalid(\"SQL text must be a NUL-free string\");\n return construct([text]);\n },\n ident: ({ parts }: { parts: readonly string[] }): SqlFragment => {\n identifier(parts);\n return construct([Object.freeze({ ident: Object.freeze([...parts]) })]);\n },\n value: <T>({ value, decoder }: { value: NoInfer<T>; decoder?: ResultDecoder<T> }): SqlFragment =>\n construct([Object.freeze({ value: snapshotSqlValue(value), ...(decoder === undefined ? {} : { decoder }) })]),\n join: ({ items, separator }: { items: readonly unknown[]; separator?: SqlFragment }): SqlFragment => {\n if (!Array.isArray(items)) invalid(\"sql.join requires an array\");\n const between = separator === undefined ? [\", \"] : partsOf(separator);\n const parts: Part[] = [];\n items.forEach((value, index) => {\n if (index > 0) parts.push(...between);\n parts.push(...(isSqlFragment(value) ? partsOf(value) : [Object.freeze({ value: snapshotSqlValue(value) })]));\n });\n return construct(parts);\n },\n existing: ({ column }: { column: string }): SqlFragment => {\n identifier([column]);\n return construct([Object.freeze({ row: \"existing\", column })]);\n },\n incoming: ({ column }: { column: string }): SqlFragment => {\n identifier([column]);\n return construct([Object.freeze({ row: \"incoming\", column })]);\n },\n greatest: ({ values }: { values: readonly SqlFragment[] }): SqlFragment => {\n if (!Array.isArray(values) || values.length !== 2 || values.some((value) => !isSqlFragment(value))) invalid(\"sql.greatest requires two SQL fragments\");\n return construct([Object.freeze({ greatest: Object.freeze([...values]) })]);\n },\n}));\n\n/** Render opaque fragments with the enclosing statement's parameter collector. */\nexport function renderSqlFragment(params: {\n dialect: SqlDialect;\n fragment: SqlFragment;\n collector: ParamCollector;\n /** Available only in a conflict update; maps logical names to physical names. */\n conflict?: { readonly table: string; readonly columns?: Readonly<Record<string, string>> };\n}): string {\n const { dialect, collector, conflict } = params;\n const render = (fragment: SqlFragment): string => renderSqlFragment({ ...params, fragment });\n const encode = (part: { readonly value: unknown; readonly decoder?: ResultDecoder<unknown> }): unknown => {\n if (part.value === undefined) invalid(\"SQL parameters cannot be undefined; use null explicitly\");\n // Never expose a fragment's captured values (or an encoder's mutable output)\n // to the driver. This isolation belongs here, not in the shared collector.\n return snapshotSqlValue(part.decoder === undefined ? part.value : part.decoder.encode({ value: snapshotSqlValue(part.value), dialect: dialect.name }));\n };\n const recording = isSqlBindingCollector({ collector });\n const recordValue = (part: { readonly value: unknown; readonly decoder?: ResultDecoder<unknown> }): string => recordSqlBinding({\n collector, source: { kind: \"literal\", value: part.value },\n transport: part.decoder === undefined ? sqlParameterTransport({ value: part.value }) : { kind: \"plain\" },\n encode: ({ value, dialect: target }) => part.decoder === undefined ? value : part.decoder.encode({ value, dialect: target.name }),\n });\n // A frame operand becomes a derived-table column. MySQL types a NULL-bound\n // parameter there as text, which turns the whole maximum into text (\"7\" for\n // 7), so a bare NULL value renders as the NULL literal. MySQL 8.4 also refuses\n // a derived-table select list that holds a nested frame beside a direct outer\n // column reference (ER_ILLEGAL_REFERENCE 1247), so `wrapped-frame` puts every\n // non-NULL operand in its own scalar subquery.\n const frameOperand = (fragment: SqlFragment): string => {\n const parts = partsOf(fragment).filter((part) => part !== \"\");\n const only = parts.length === 1 ? parts[0] : undefined;\n if (recording && only !== undefined && typeof only !== \"string\" && \"value\" in only) {\n if (only.decoder !== undefined && resultScalarContract({ decoder: only.decoder }) === undefined) throw new VibeError({ code: \"VIBE_UNSUPPORTED_CAPABILITY\", message: \"Reusable SQL cannot compile an opaque encoder whose output controls a greatest NULL frame\" });\n if (only.value === null) {\n if (only.decoder !== undefined) recordSqlBindingCheck({ collector, check: () => {\n if (encode({ ...only, value: snapshotSqlValue(only.value) }) !== null) throw new VibeError({ code: \"VIBE_UNSUPPORTED_CAPABILITY\", message: \"Reusable SQL NULL frame encoding changed its declared structure\" });\n } });\n return \"NULL\";\n }\n const text = recordValue(only);\n return dialect.greatestForm === \"wrapped-frame\" ? `(SELECT ${text})` : text;\n }\n const value = only !== undefined && typeof only !== \"string\" && \"value\" in only ? { encoded: encode(only) } : undefined;\n if (value !== undefined && value.encoded === null) return \"NULL\";\n const text = value === undefined ? render(fragment) : collector.add(value.encoded);\n return dialect.greatestForm === \"wrapped-frame\" ? `(SELECT ${text})` : text;\n };\n return partsOf(params.fragment).map((part) => {\n if (typeof part === \"string\") return part;\n if (\"value\" in part) return recording ? recordValue(part) : collector.add(encode(part));\n if (\"ident\" in part) return part.ident.map((name) => dialect.quoteIdent({ name })).join(\".\");\n if (\"row\" in part) {\n if (conflict === undefined) invalid(\"Existing/incoming row references require a conflict update\");\n const name = conflict.columns === undefined ? part.column : conflict.columns[part.column];\n if (name === undefined) invalid(`Unknown conflict-expression field \"${part.column}\"`);\n const ref = dialect.excludedRowRef;\n const qualifier = part.row === \"existing\" ? dialect.quoteIdent({ name: conflict.table })\n : ref.form === \"keyword\" ? ref.name : dialect.quoteIdent({ name: ref.alias });\n return `${qualifier}.${dialect.quoteIdent({ name })}`;\n }\n // Each operand renders once, so nesting stays linear in text and parameters.\n if (dialect.greatestForm === \"native\") return `GREATEST(${part.greatest.map(render).join(\", \")})`;\n // A node whose operands hold no greatest keeps the 2.x CASE form byte for\n // byte (its semantics, result type, collation precedence and aggregate\n // scope). Its repetitions re-render so anonymous placeholders still bind\n // one value each; only these innermost nodes repeat, so nesting stays linear.\n if (!part.greatest.some(containsGreatest)) {\n return render(part.greatest.reduce((left, right) => sql`(CASE WHEN ${left} IS NULL THEN ${right} WHEN ${right} IS NULL THEN ${left} WHEN ${left} >= ${right} THEN ${left} ELSE ${right} END)`));\n }\n const [left, right] = part.greatest.map(frameOperand) as [string, string];\n // The frame binds each operand to a column once; CASE then gives PostgreSQL's\n // NULL-ignoring maximum semantics without repeating operand SQL or values.\n const [a, b, frame] = [\"a\", \"b\", \"g\"].map((name) => dialect.quoteIdent({ name })) as [string, string, string];\n return `(SELECT CASE WHEN ${a} IS NULL THEN ${b} WHEN ${b} IS NULL THEN ${a} WHEN ${a} >= ${b} THEN ${a} ELSE ${b} END FROM (SELECT ${left} AS ${a}, ${right} AS ${b}) AS ${frame})`;\n }).join(\"\");\n}\n\n/** Resolve logical conflict references once, before rendering or executing any row. */\nexport function mapConflictColumns(params: { fragment: SqlFragment; columns: Readonly<Record<string, string>> }): SqlFragment {\n return construct(partsOf(params.fragment).map((part): Part => {\n if (typeof part === \"string\") return part;\n if (\"row\" in part) {\n const column = Object.hasOwn(params.columns, part.column) ? params.columns[part.column] : undefined;\n if (column === undefined) invalid(`Unknown conflict-expression field \"${part.column}\"`);\n return Object.freeze({ ...part, column });\n }\n if (\"greatest\" in part) return Object.freeze({ greatest: Object.freeze(part.greatest.map((fragment) => mapConflictColumns({ ...params, fragment }))) });\n return part;\n }));\n}\n\n/** Render a complete constructed query. */\nexport function compileSql(params: { dialect: SqlDialect; query: SqlFragment }): { text: string; values: unknown[] } {\n const collector = new ParamCollector(params.dialect);\n const text = renderSqlFragment({ dialect: params.dialect, fragment: params.query, collector });\n return { text, values: collector.values };\n}\n\n/** Whether a nested SQL fragment reads the incoming row (MySQL alias declaration). */\nexport function sqlUsesIncoming(params: { fragment: SqlFragment }): boolean {\n return partsOf(params.fragment).some((part) => typeof part !== \"string\" &&\n ((\"row\" in part && part.row === \"incoming\") || (\"greatest\" in part && part.greatest.some((fragment) => sqlUsesIncoming({ fragment })))));\n}\n",
39
39
  "import { VibeError } from \"@vibeorm/schema\";\nimport { isSqlFragment } from \"./composable.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { ParamCollector } from \"./params.ts\";\nimport { registerSqlHandleCheck } from \"./sql-handles.ts\";\nimport type { ResultReadDecoder } from \"./result-decoder.ts\";\nimport { bindSqlBindingProgram, finishSqlBindingCollection, startSqlBindingCollection } from \"./sql-bindings.ts\";\nimport type { SqlBindingProgram } from \"./sql-bindings.ts\";\nimport { isSqlInput, sqlInputScopeHandle, sqlInputScopeKeys } from \"./sql-input.ts\";\nimport type { SqlInputScope } from \"./sql-input.ts\";\n\ndeclare const queryBrand: unique symbol;\ndeclare const commandBrand: unique symbol;\n/** Authentic row-returning SQL plan, independent of a client or transaction. */\nexport type SqlQuery<Row> = { readonly [queryBrand]: Row };\n/** Authentic affected-count SQL plan; never a row-returning contract. */\nexport type SqlCommand = { readonly [commandBrand]: true };\n/** Render into the enclosing collector, preserving parameter order in compositions. */\nexport type SqlPlanRender = (params: { dialect: SqlDialect; collector: ParamCollector }) => string;\n/** Compiled row query and its captured runtime result contract. */\nexport type CompiledSqlQuery<Row> = { readonly text: string; readonly values: unknown[]; readonly decoder: ResultReadDecoder<Row> };\n\ntype QueryState = { readonly render: SqlPlanRender; readonly decoder: ResultReadDecoder<unknown> };\nconst queries = new WeakMap<object, QueryState>();\nconst commands = new WeakMap<object, SqlPlanRender>();\n\ndeclare const reusableQueryBrand: unique symbol;\ndeclare const reusableCommandBrand: unique symbol;\n/** Ownerless fixed SQL with required execution inputs and its own result decoder. */\nexport type ReusableSqlQuery<Params extends object, Row> = { readonly [reusableQueryBrand]: { readonly params: Params; readonly row: Row } };\n/** Ownerless fixed affected-count SQL with required execution inputs. */\nexport type ReusableSqlCommand<Params extends object> = { readonly [reusableCommandBrand]: Params };\n/** A fresh bound command, ready for the existing raw execution route. */\nexport type CompiledSqlCommand = { readonly text: string; readonly values: unknown[] };\ntype CompiledTemplate = { readonly text: string; readonly program: SqlBindingProgram };\ntype TemplateState = { readonly render: SqlPlanRender; readonly scope: SqlInputScope; readonly decoder?: ResultReadDecoder<unknown>; readonly cache: WeakMap<SqlDialect, CompiledTemplate> };\nconst reusableQueries = new WeakMap<object, TemplateState>();\nconst reusableCommands = new WeakMap<object, TemplateState>();\nregisterSqlHandleCheck({ check: (value) => queries.has(value) || commands.has(value) || reusableQueries.has(value) || reusableCommands.has(value) });\n\nfunction invalid(message: string): never {\n throw new VibeError({ code: \"VIBE_VALIDATION\", message });\n}\n\n/** Capture a renderer and decoder without opening any execution resource. */\nexport function createSqlQuery<Row>(params: { render: SqlPlanRender; decoder: ResultReadDecoder<Row> }): SqlQuery<Row> {\n if (typeof params.render !== \"function\" || typeof params.decoder?.decode !== \"function\") invalid(\"SQL queries require a renderer and result decoder\");\n const query = Object.freeze(Object.create(null)) as SqlQuery<Row>;\n queries.set(query, Object.freeze({ render: params.render, decoder: params.decoder }));\n return query;\n}\n\n/** Capture a command renderer without inventing a result-row contract. */\nexport function createSqlCommand(params: { render: SqlPlanRender }): SqlCommand {\n if (typeof params.render !== \"function\") invalid(\"SQL commands require a renderer\");\n const command = Object.freeze(Object.create(null)) as SqlCommand;\n commands.set(command, params.render);\n return command;\n}\n\n/** Structural copies and assertions are not executable row plans. */\nexport function isSqlQuery(value: unknown): value is SqlQuery<unknown> {\n return typeof value === \"object\" && value !== null && queries.has(value);\n}\n\n/** Structural copies and row plans are not executable commands. */\nexport function isSqlCommand(value: unknown): value is SqlCommand {\n return typeof value === \"object\" && value !== null && commands.has(value);\n}\n\n/** Authentic reusable row plans are distinct from ordinary composable plans. */\nexport function isReusableSqlQuery(value: unknown): value is ReusableSqlQuery<object, unknown> {\n return typeof value === \"object\" && value !== null && reusableQueries.has(value);\n}\n\n/** Authentic reusable commands never masquerade as row queries. */\nexport function isReusableSqlCommand(value: unknown): value is ReusableSqlCommand<object> {\n return typeof value === \"object\" && value !== null && reusableCommands.has(value);\n}\n\n/** @internal Query-bundle provenance is checked by qb.reusable before this bridge. */\nexport function createReusableSqlQuery<P extends object, Row>(params: { query: SqlQuery<Row>; scope: SqlInputScope }): ReusableSqlQuery<P, Row> {\n const state = queries.get(params.query) ?? invalid(\"Expected an authentic SQL row query\");\n sqlInputScopeKeys({ scope: params.scope });\n const query = Object.freeze(Object.create(null)) as ReusableSqlQuery<P, Row>;\n reusableQueries.set(query, { ...state, scope: params.scope, cache: new WeakMap() });\n return query;\n}\n\n/** @internal Wrap an admitted builder command without capturing an execution owner. */\nexport function createReusableSqlCommand<P extends object>(params: { query: SqlCommand; scope: SqlInputScope }): ReusableSqlCommand<P> {\n const render = commands.get(params.query) ?? invalid(\"Expected an authentic SQL command\");\n sqlInputScopeKeys({ scope: params.scope });\n const query = Object.freeze(Object.create(null)) as ReusableSqlCommand<P>;\n reusableCommands.set(query, { render, scope: params.scope, cache: new WeakMap() });\n return query;\n}\n\nfunction compiledTemplate(params: { dialect: SqlDialect; state: TemplateState }): CompiledTemplate {\n const cached = params.state.cache.get(params.dialect);\n if (cached !== undefined) return cached;\n const collector = new ParamCollector(params.dialect);\n startSqlBindingCollection({ collector, dialect: params.dialect, scope: params.state.scope });\n const text = params.state.render({ dialect: params.dialect, collector });\n if (collector.count() > params.dialect.paramBudget) invalid(\"SQL query exceeds this dialect's parameter budget; statements are never split implicitly\");\n const program = finishSqlBindingCollection({ collector });\n const compiled = Object.freeze({ text, program });\n params.state.cache.set(params.dialect, compiled);\n return compiled;\n}\n\n/** Core and builder handles are SQL code, never execution data, at any depth of an input bag. */\nfunction executionHandle(params: { scope: SqlInputScope; value: object }): boolean {\n const { value } = params;\n return queries.has(value) || commands.has(value) || reusableQueries.has(value) || reusableCommands.has(value)\n || isSqlFragment(value) || isSqlInput(value) || sqlInputScopeHandle(params);\n}\n\nfunction bindTemplate(params: { compiled: CompiledTemplate; state: TemplateState; inputs: unknown }): unknown[] {\n const { scope } = params.state;\n return bindSqlBindingProgram({ program: params.compiled.program, params: params.inputs, isHandle: (value) => executionHandle({ scope, value }) });\n}\n\n/** Compile structure once per dialect and synchronously snapshot/bind this invocation. */\nexport function compileReusableSqlQuery<P extends object, Row>(params: { readonly dialect: SqlDialect; readonly query: ReusableSqlQuery<P, Row>; readonly params?: unknown }): CompiledSqlQuery<Row> {\n const state = reusableQueries.get(params.query) ?? invalid(\"Expected an authentic reusable SQL row query\");\n const compiled = compiledTemplate({ dialect: params.dialect, state });\n return { text: compiled.text, values: bindTemplate({ compiled, state, inputs: params.params }), decoder: state.decoder as ResultReadDecoder<Row> };\n}\n\n/** Compile structure once per dialect and bind a fresh affected-count command. */\nexport function compileReusableSqlCommand<P extends object>(params: { readonly dialect: SqlDialect; readonly query: ReusableSqlCommand<P>; readonly params?: unknown }): CompiledSqlCommand {\n const state = reusableCommands.get(params.query) ?? invalid(\"Expected an authentic reusable SQL command\");\n const compiled = compiledTemplate({ dialect: params.dialect, state });\n return { text: compiled.text, values: bindTemplate({ compiled, state, inputs: params.params }) };\n}\n\n/** Compile a row plan once the execution dialect is known. */\nexport function compileSqlQuery<Row>(params: { dialect: SqlDialect; query: SqlQuery<Row> }): CompiledSqlQuery<Row> {\n const state = queries.get(params.query) ?? invalid(\"Expected an authentic SQL row query\");\n const collector = new ParamCollector(params.dialect);\n const text = state.render({ dialect: params.dialect, collector });\n if (collector.values.length > params.dialect.paramBudget) invalid(\"SQL query exceeds this dialect's parameter budget; statements are never split implicitly\");\n return { text, values: collector.values, decoder: state.decoder as ResultReadDecoder<Row> };\n}\n\n/** Compile an affected-count plan; row terminals are refused. */\nexport function compileSqlCommand(params: { dialect: SqlDialect; query: SqlCommand }): { text: string; values: unknown[] } {\n const render = commands.get(params.query) ?? invalid(\"Expected an authentic SQL command\");\n const collector = new ParamCollector(params.dialect);\n const text = render({ dialect: params.dialect, collector });\n if (collector.values.length > params.dialect.paramBudget) invalid(\"SQL command exceeds this dialect's parameter budget; statements are never split implicitly\");\n return { text, values: collector.values };\n}\n",
40
40
  "import { VibeError, fieldTypeIdentity, isEnumType, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { ExclusionEndpoint, ExclusionIR, ExclusionSpec, FieldIR, ModelIR } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { renderPredicate } from \"./predicate.ts\";\n\nfunction invalid(rule: string): never {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: `Invalid exclusion constraint: ${rule}`, meta: { rule: `exclusion-${rule}` } });\n}\n\n/** Compile immutable range construction and equality operands using physical column names. */\nexport function compileExclusion(params: { exclusion: ExclusionSpec; model: Pick<ModelIR, \"name\" | \"fields\">; dialect: SqlDialect }): ExclusionIR {\n const { exclusion: spec, model, dialect } = params;\n if (!dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: dialect.name, feature: \"exclusionConstraints\" });\n if (!spec.name || spec.name.includes(\"\\0\")) invalid(\"name\");\n if (![\"int8range\", \"tsrange\", \"tstzrange\"].includes(spec.range.type)) invalid(\"range-type\");\n if (![\"[)\", \"[]\", \"()\", \"(]\"].includes(spec.range.bounds)) invalid(\"bounds\");\n const field = (name: string): FieldIR => {\n const value = model.fields.find((entry) => entry.name === name);\n if (value === undefined || value.isList || value.isUnsupported) invalid(\"field\");\n return value;\n };\n const endpoint = (value: ExclusionEndpoint): string => {\n if (\"unbounded\" in value) return \"NULL\";\n const infinity = \"infinity\" in value ? value.infinity : value.nullAs;\n if (infinity !== undefined && (spec.range.type === \"int8range\" || ![\"infinity\", \"-infinity\"].includes(infinity))) invalid(\"infinity\");\n const literal = infinity === undefined ? undefined : `${dialect.quoteStringLiteral({ value: infinity })}::${spec.range.type === \"tsrange\" ? \"timestamp\" : \"timestamptz\"}`;\n if (\"infinity\" in value) return literal!;\n const column = field(value.field);\n if (fieldTypeIdentity({ type: column.type }) !== (spec.range.type === \"int8range\" ? \"BigInt\" : \"DateTime\")) invalid(\"range-field-type\");\n if (column.type === \"DateTime\") {\n const timezone = /timestamptz|timestamp.*with time zone/i.test(column.nativeType ?? \"timestamptz\");\n if (timezone !== (spec.range.type === \"tstzrange\")) invalid(\"range-timezone\");\n }\n const sql = dialect.quoteIdent({ name: column.dbName ?? column.name });\n return literal === undefined ? sql : `COALESCE(${sql}, ${literal})`;\n };\n const keys = spec.keys.map((key) => {\n if (\"expression\" in key) {\n if (!key.expression.trim() || key.expression.includes(\"\\0\") || key.fields.length === 0) invalid(\"expression\");\n key.fields.forEach(field);\n return `(${key.expression}) WITH =`;\n }\n const column = field(key.field);\n if (column.isOptional) invalid(\"nullable-key-requires-expression\");\n if (!isEnumType(column.type) && ![\"String\", \"Int\", \"BigInt\", \"Float\", \"Decimal\", \"Boolean\", \"DateTime\"].includes(fieldTypeIdentity({ type: column.type }))) invalid(\"key-type\");\n return `${dialect.quoteIdent({ name: column.dbName ?? column.name })} WITH =`;\n });\n keys.push(`${spec.range.type}(${endpoint(spec.range.lower)}, ${endpoint(spec.range.upper)}, ${dialect.quoteStringLiteral({ value: spec.range.bounds })}) WITH &&`);\n const where = spec.where === undefined ? \"\" : ` WHERE (${renderPredicate({ predicate: spec.where, model, dialect, usage: \"exclusionPredicate\", site: spec.name })})`;\n return { name: spec.name, definition: `EXCLUDE USING gist (${keys.join(\", \")})${where}`, source: spec, requiredExtensions: spec.keys.length === 0 ? [] : dialect.capabilities.exclusionExtensions };\n}\n\n/** Exclusion DDL is a constraint operation, never an index operation. */\nexport function renderExclusionSetup(params: { dialect: SqlDialect; exclusion: ExclusionIR }): string[] {\n if (!params.dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: params.dialect.name, feature: \"exclusionConstraints\" });\n return params.exclusion.requiredExtensions.map((name) => `CREATE EXTENSION IF NOT EXISTS ${params.dialect.quoteIdent({ name })};`);\n}\n\nexport function renderExclusionDdl(params: { dialect: SqlDialect; table: string; exclusion: ExclusionIR; operation: \"add\" | \"drop\" }): string[] {\n const { dialect, table, exclusion, operation } = params;\n if (!dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: dialect.name, feature: \"exclusionConstraints\" });\n const target = `ALTER TABLE ${dialect.quoteIdent({ name: table })}`;\n if (operation === \"drop\") return [`${target} DROP CONSTRAINT ${dialect.quoteIdent({ name: exclusion.name })};`];\n return [...renderExclusionSetup({ dialect, exclusion }), `${target} ADD CONSTRAINT ${dialect.quoteIdent({ name: exclusion.name })} ${exclusion.definition};`];\n}\n\n/** Read catalog exclusion definitions, including index health; optional private probe table. */\nexport function renderExclusionCatalog(params: { dialect: SqlDialect; probe?: string; namespace?: string }): string {\n const { dialect, probe } = params;\n if (!dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: dialect.name, feature: \"exclusionConstraints\" });\n const scope = probe === undefined ? `n.nspname = ${dialect.quoteStringLiteral({ value: params.namespace ?? \"public\" })}` : `t.oid = ${dialect.quoteStringLiteral({ value: probe })}::regclass`;\n return `SELECT t.relname AS table_name, c.conname AS constraint_name, pg_catalog.pg_get_constraintdef(c.oid, true) AS definition, c.convalidated AS validated, i.indisvalid AS valid, i.indisready AS ready FROM pg_catalog.pg_constraint c JOIN pg_catalog.pg_class t ON t.oid = c.conrelid JOIN pg_catalog.pg_namespace n ON n.oid = t.relnamespace JOIN pg_catalog.pg_index i ON i.indexrelid = c.conindid WHERE c.contype = 'x' AND ${scope} ORDER BY t.relname, c.conname`;\n}\n\n/** Empty private clone for server normalization; no existing row is scanned or changed. */\nexport function renderExclusionProbe(params: { dialect: SqlDialect; table: string; namespace?: string; probe: string; definition: string }): string[] {\n const { dialect, table, probe, definition } = params;\n if (!dialect.capabilities.exclusionConstraints) throw unsupportedCapability({ dialect: dialect.name, feature: \"exclusionConstraints\" });\n return [`CREATE TEMP TABLE ${dialect.quoteIdent({ name: probe })} (LIKE ${dialect.quoteIdent({ name: params.namespace ?? \"public\" })}.${dialect.quoteIdent({ name: table })})`, `ALTER TABLE ${dialect.quoteIdent({ name: probe })} ADD CONSTRAINT ${dialect.quoteIdent({ name: `${probe}_x` })} ${definition}`];\n}\n",
41
- "import type { NativeEnumArrayParameter } from \"./native-enum-parameter.ts\";\nimport type { JsonListParameter } from \"./json-list-parameter.ts\";\nimport type { SqlFragment } from \"./composable.ts\";\nimport type { RlsReadinessQuery } from \"./dialects/postgres-rls-readiness.ts\";\n/**\n * The SQL AST — the small statement language the runtime and migrate packages\n * build and dialects render.\n *\n * Deliberately minimal at P0 (single-table statements, no joins/subqueries);\n * grows with the runtime in P2/P3. Every shape added here needs a catalog case\n * (tests/catalog/cases.ts) in the same change.\n */\n\nimport type {\n AdvisoryLockMode,\n RlsContextIR,\n RowLockStrength,\n RowLockWaitPolicy,\n ScalarType,\n SchemaIR,\n SqlFragmentSpec,\n} from \"@vibeorm/schema\";\n\n// ─── References ───────────────────────────────────────────────────\n\n/** A column reference, optionally table-qualified. */\nexport type ColRef = {\n readonly table?: string;\n readonly name: string;\n /**\n * Projection-only wire transform. `jsonText` uses the dialect's JSON text\n * projection to preserve SQL NULL versus the JSON document `null` before\n * driver parsing, without converting a postgres `json` column to `jsonb`.\n * `castText` renders a dialect text cast and preserves `alias ?? name`,\n * including timestamp identity before driver Date truncation. PostgreSQL\n * uses `\"col\"::text`; SQLite/MySQL use CAST AS TEXT/CHAR. `encodeBase64`\n * is postgres-only and renders `encode(\"col\", 'base64')`.\n * `encodeArrayBase64` is postgres-only and renders\n * `encode(array_send(\"col\"), 'base64')` — a `bytea[]` column's binary array\n * form (dimensions, NULL elements, raw element bytes) as base64: faithful\n * whatever the session's `bytea_output`, keeping a NULL column (`NULL`), an\n * empty array and NULL elements distinct (5.0 lane V; the lateral subselect's\n * `Bytes[]` form, decoded by the runtime's JSON-transport plan). Other users:\n * the lateral subselect (SQL review B3: raw `to_jsonb` would ship BigInt/Decimal as float64 JSON\n * numbers and Bytes as `\\x` hex text), and every row projection of a\n * `Float[]`/`Json[]` column (bun:sql's array parser refuses float arrays\n * printed with an exponent and json arrays holding integers beyond int32;\n * the runtime parses the array literal text itself). Never set on\n * filter/order refs.\n */\n readonly transform?: \"castText\" | \"encodeBase64\" | \"encodeArrayBase64\" | \"jsonText\";\n /**\n * Comparison/order/aggregate cast, sqlite Decimal only (SQL review B4):\n * Decimal stores as exact TEXT there and text comparison is lexicographic —\n * compare, ORDER BY and aggregate sites render `CAST(\"col\" AS REAL)` (with\n * NUMBER operands) instead. Never set on projections or GROUP BY keys, so\n * storage and read-back stay the exact text.\n */\n readonly castReal?: boolean;\n /**\n * Order/distinct/compare cast, postgres `json` columns only (`Json @db.Json`,\n * release-3.0 D3): `json` has no ordering or equality operator, so ORDER BY,\n * DISTINCT ON and comparison sites render `\"col\"::jsonb` (`\"col\"::jsonb[]`\n * for a `json[]` list column) — the order and distinctness of a jsonb\n * column. Never set on projections, so read-back keeps the stored text.\n */\n readonly castJsonb?: \"jsonb\" | \"jsonb[]\";\n /**\n * Projection alias: renders `ref AS \"alias\"`. PROJECTION-ONLY — filter,\n * order and correlation refs never set it (the renderer ignores it outside\n * a projection list). Used by the single-statement M2M join to expose the\n * join table's parent-key column under a reserved name (`__vibe_parent`).\n */\n readonly alias?: string;\n};\n\nexport type TableRef = {\n readonly name: string;\n /** Explicit fixed PostgreSQL placement; absence preserves existing SQL. */\n readonly namespace?: string;\n readonly alias?: string;\n};\n\n// ─── Aggregates ───────────────────────────────────────────────────\n\n/** Aggregate functions applied to one column. */\nexport type AggFn = \"count\" | \"avg\" | \"sum\" | \"min\" | \"max\";\n\n/** Reference to an aggregate expression: `COUNT(*)` or `FN(\"col\")`. */\nexport type AggRef =\n | { readonly fn: \"countAll\" }\n | { readonly fn: AggFn; readonly column: ColRef };\n\n/**\n * One aggregate projection: `FN(\"col\") AS \"alias\"`. The alias is part of the\n * catalog contract — the runtime derives result keys from it deterministically\n * (`_count___all`, `_avg__score`), never by parsing the SQL text back.\n */\nexport type AggSelect = {\n readonly agg: AggRef;\n readonly alias: string;\n /** Projection-only result cast; native aggregate comparisons and ordering stay typed. */\n readonly castText?: true;\n};\n\n// ─── JSON filters ─────────────────────────────────────────────────\n\n/**\n * JSON path predicates (Prisma's Json filter surface). `not` is `equals` with\n * `negate` — there is no separate op. Which ops a dialect can express is\n * declared on `SqlDialect.supportedJsonOps` and enforced at render time too.\n */\nexport type JsonFilterOp =\n | \"equals\"\n | \"string_contains\"\n | \"string_starts_with\"\n | \"string_ends_with\"\n | \"array_contains\"\n | \"array_starts_with\"\n | \"array_ends_with\";\n\n// ─── Expressions ──────────────────────────────────────────────────\n\nexport type ComparisonOp = \"eq\" | \"ne\" | \"gt\" | \"gte\" | \"lt\" | \"lte\";\n\n/**\n * The column facts one member of a {@link SqlExpr} `keyList` tuple needs to\n * bind exactly like the equality `\"col\" = $n` would. Postgres binds each\n * member as ONE typed array (`$n::<element type>[]`), so it needs the\n * column's element type: the declared native type without its modifier\n * (`timestamptz`, never `timestamptz(3)` — a typmod cast would round\n * `.1234` onto a stored `.123` that `=` does not match), `bpchar` for\n * `char(n)`, `citext`, the enum's own type. MySQL needs to know a time-of-day\n * member (`SqlDialect.timeOfDayInStrategy`); SQLite needs nothing.\n */\nexport type KeyListMember = {\n /** The column's scalar type; `\"Enum\"` for an enum column. */\n readonly type: ScalarType | \"Enum\";\n /** The declared `@db.*` native type, verbatim (`VarChar(191)`, `Uuid`, `Timestamptz(3)`). */\n readonly nativeType?: string;\n /**\n * A database-stored (native) enum's type: `namespace` qualifies it, absence\n * resolves it through the search path like the statement's table. Absent on\n * a string-stored enum, whose column is text.\n */\n readonly enumType?: { readonly namespace?: string; readonly name: string };\n /** A time-of-day column (`@db.Time(n)` / `@db.Timetz(n)`). */\n readonly timeOfDay?: boolean;\n};\n\nexport type SqlExpr =\n | { readonly kind: \"composed\"; readonly fragment: SqlFragment }\n | { readonly kind: \"cmp\"; readonly op: ComparisonOp; readonly column: ColRef; readonly value: unknown }\n /** Column-to-column comparison — the correlation predicate of EXISTS/lateral subqueries. */\n | { readonly kind: \"cmpCol\"; readonly op: ComparisonOp; readonly left: ColRef; readonly right: ColRef }\n | { readonly kind: \"isNull\"; readonly column: ColRef; readonly negate?: boolean }\n | {\n readonly kind: \"inArray\";\n readonly column: ColRef;\n readonly values: readonly unknown[];\n readonly negate?: boolean;\n /**\n * The column holds a time of day (`@db.Time(n)` / `@db.Timetz(n)`): the\n * dialect renders the membership per `SqlDialect.timeOfDayInStrategy`.\n */\n readonly timeOfDay?: boolean;\n }\n /**\n * ORDERED-TUPLE membership: `(\"a\", \"b\") IN ((?, ?), (?, ?))`. The composite\n * relation predicate — `\"a\" IN (…) AND \"b\" IN (…)` is a Cartesian SUPERSET\n * and is never a substitute. Renders per `SqlDialect.tupleInStrategy`:\n * a native row-value `IN` where the dialect has row constructors, else an OR\n * of COMPLETE conjunctions. Arity 1 is expressed as {@link SqlExpr} `inArray`\n * instead, so single-key relations keep their existing SQL.\n */\n | {\n readonly kind: \"tupleIn\";\n /** Ordered tuple columns; `rows[i][j]` binds to `columns[j]`. */\n readonly columns: readonly ColRef[];\n /** Candidate tuples — every row carries exactly `columns.length` values. */\n readonly rows: readonly (readonly unknown[])[];\n readonly negate?: boolean;\n }\n /**\n * KEY-LIST membership — the public `where: { IN: [{ a, b }, …] }` filter:\n * rows whose ordered tuple of column values equals one of `rows`, with\n * semi-join semantics (a repeated tuple never repeats a result row). Renders\n * per `SqlDialect.keyListStrategy`: postgres binds one typed ARRAY per\n * member, `(\"a\", \"b\") IN (SELECT * FROM unnest($1::int8[], $2::text[]))`,\n * so the text and the planning cost stay constant however long the list is\n * (an OR of 1 000 conjunctions planned in 114 ms on PGlite, 2 ms on\n * postgres 18; the unnest form in 0.1–0.2 ms on both). A `DateTime` member\n * without a declared native type switches postgres to the row-constructor\n * list of untyped parameters (`keyListBindsUntypedRows`: the column may be a\n * zone-less `timestamp`). MySQL renders the row-constructor list, SQLite\n * `IN (VALUES …)`. Each member compares under the column's own type and\n * collation, exactly like `\"col\" = $n`.\n *\n * An empty `rows` renders `1 = 0` (matches nothing, like an empty\n * `inArray`). The runtime emits arity 1 as `inArray` instead, so a\n * one-field key list keeps the scalar `in` SQL.\n */\n | {\n readonly kind: \"keyList\";\n /** Ordered tuple columns (compare references); `rows[i][j]` binds to `columns[j]`. */\n readonly columns: readonly ColRef[];\n /** How each member binds, in column order — see {@link KeyListMember}. */\n readonly members: readonly KeyListMember[];\n /** Encoded candidate tuples, each exactly `columns.length` long; may repeat. */\n readonly rows: readonly (readonly unknown[])[];\n }\n /**\n * ROW-VALUE comparison: `(\"a\", \"b\") > ($1, $2)` — the keyset seek (D-01).\n * SQL compares row values left to right, each pair with that column's own\n * operator, affinity and collation, which is exactly the OR expansion\n * `\"a\" > $1 OR (\"a\" = $2 AND \"b\" > $3)` when no member is NULL — and an\n * index on `(a, b)` bounds it as one range (PostgreSQL `Index Cond: ROW(…) >\n * ROW(…)`, SQLite `SEARCH … (a>?)`). A NULL member makes the comparison\n * UNKNOWN as soon as the scan reaches it, so the runtime emits it only over\n * non-null keys and values. Renders on every dialect (each has row\n * constructors); whether the runtime emits it is\n * `SqlDialect.keysetSeekStrategy`.\n */\n | {\n readonly kind: \"rowCompare\";\n readonly op: \"gt\" | \"gte\" | \"lt\" | \"lte\";\n /** Ordered row members (compare references); `values[i]` binds to `columns[i]`. */\n readonly columns: readonly ColRef[];\n /** Encoded values, exactly `columns.length` of them. */\n readonly values: readonly unknown[];\n }\n /**\n * SUBQUERY membership: `\"id\" IN (SELECT …)`, or the row-value form\n * `(\"a\", \"b\") IN (SELECT …)` for a composite key — the key-first `distinct`\n * page on PostgreSQL (D-04). The subquery projects exactly `columns.length`\n * columns and shares the statement's parameter sequence. MySQL refuses a\n * `LIMIT` directly inside an `IN` subquery (error 1235), so the renderer\n * refuses that pair there with `VIBE_UNSUPPORTED_CAPABILITY`.\n */\n | {\n readonly kind: \"inSelect\";\n /** The tested columns, in the subquery's projection order. */\n readonly columns: readonly ColRef[];\n readonly select: SelectStatement;\n }\n | {\n readonly kind: \"like\";\n readonly column: ColRef;\n /** Pre-built pattern (see like.ts helpers for escaping). */\n readonly pattern: string;\n readonly insensitive?: boolean;\n /**\n * The column carries an explicit case-insensitive collation (@collation\n * `…_ci`, board #36): an insensitive match renders as PLAIN `LIKE` — the\n * collation already folds case, and skipping LOWER() keeps the column\n * indexable. Set by the builder for mysql only.\n */\n readonly ciCollation?: boolean;\n readonly negate?: boolean;\n }\n /**\n * Case-SENSITIVE string match (`mode: \"strict\"`, board #20). `value` is the\n * RAW operand — pattern building happens at render time because escaping\n * differs per strategy (LIKE's `%`/`_`/`\\` vs GLOB's `*`/`?`/`[`). Renders\n * per `SqlDialect.strictMatchStrategy`: plain `=`/`LIKE` on postgres\n * (already byte-sensitive — a deliberate, documented no-op), `=`/`GLOB` on\n * sqlite, `= CAST(? AS BINARY)`/`LIKE CAST(? AS BINARY)` on mysql. The\n * non-native forms defeat plain indexes; docs/dialect-notes.md carries the\n * cost and the functional/`_bin`-index mitigation.\n */\n | {\n readonly kind: \"strictMatch\";\n readonly column: ColRef;\n readonly op: \"equals\" | \"contains\" | \"startsWith\" | \"endsWith\";\n readonly value: string;\n readonly negate?: boolean;\n }\n | { readonly kind: \"and\"; readonly operands: readonly SqlExpr[] }\n | { readonly kind: \"or\"; readonly operands: readonly SqlExpr[] }\n | { readonly kind: \"not\"; readonly operand: SqlExpr }\n /**\n * Correlated subquery test: `[NOT] EXISTS (SELECT …)`. The inner select\n * correlates to the outer scope through table-qualified `cmpCol` predicates;\n * its parameters merge into the statement's single parameter sequence in\n * render order. Relation filters (`some`/`every`/`none`/`is`/`isNot`)\n * compile to this shape.\n */\n | { readonly kind: \"exists\"; readonly select: SelectStatement; readonly negate?: boolean }\n /** Aggregate comparison — the HAVING predicate: `COUNT(\"col\") > $n`. */\n | { readonly kind: \"aggCmp\"; readonly op: ComparisonOp; readonly agg: AggRef; readonly value: unknown }\n /**\n * Scalar-list membership: `$n = ANY(\"col\")` — Prisma's `has`. Postgres only\n * (`capabilities.scalarArrays`); other dialects refuse at render time.\n */\n | { readonly kind: \"arrayHas\"; readonly column: ColRef; readonly value: unknown; readonly negate?: boolean }\n /** Scalar-list superset: `\"col\" @> $n` (one array param) — Prisma's `hasEvery`. Postgres only. */\n | { readonly kind: \"arrayContainsAll\"; readonly column: ColRef; readonly values: readonly unknown[] | string | NativeEnumArrayParameter | JsonListParameter }\n /** Scalar-list overlap: `\"col\" && $n` (one array param) — Prisma's `hasSome`. Postgres only. */\n | { readonly kind: \"arrayOverlaps\"; readonly column: ColRef; readonly values: readonly unknown[] | string | NativeEnumArrayParameter | JsonListParameter }\n /**\n * Scalar-list emptiness via `array_length(\"col\", 1) IS [NOT] NULL` — the v1\n * semantics kept deliberately: `empty: true` matches NULL **and** empty\n * arrays, `empty: false` matches only rows with at least one element.\n */\n | { readonly kind: \"arrayIsEmpty\"; readonly column: ColRef; readonly empty: boolean }\n /**\n * JSON path predicate. The path is always BOUND as a parameter (a `text[]`\n * on postgres, a `$.a.b[0]` path string on sqlite/mysql) — path segments\n * never become SQL text. `value` is the RAW JS operand; each dialect decides\n * its wire form (JSON.stringify for jsonb/json comparisons, LIKE patterns\n * for the string ops). `insensitive` applies to the string ops only.\n */\n | {\n readonly kind: \"jsonFilter\";\n readonly column: ColRef;\n readonly path: readonly (string | number)[];\n readonly op: JsonFilterOp;\n readonly value: unknown;\n readonly insensitive?: boolean;\n readonly negate?: boolean;\n /**\n * The column's postgres type: absent (or `jsonb`) for the default\n * `jsonb`, `json` for `Json @db.Json`. Postgres defines `=`, `<>` and\n * `@>` for jsonb only, so on a `json` column every op casts the\n * EXTRACTED value to jsonb (the string ops then read it as text), which\n * gives a jsonb column's answer. Sqlite and mysql have one JSON type\n * and ignore it.\n */\n readonly storage?: \"jsonb\" | \"json\";\n }\n /**\n * A bound extension fragment: literal text, bound parameters and quoted\n * identifiers in order (extensions.md §3 sql plane — trgm operators, rank\n * and distance terms). Parameters flow through the shared ParamCollector,\n * identifiers through dialect.quoteIdent — never hand-written.\n */\n | { readonly kind: \"fragment\"; readonly fragment: SqlFragmentSpec }\n /** Escape hatch for dialect-reviewed fragments. Text only — no parameters. */\n | { readonly kind: \"raw\"; readonly text: string };\n\n// ─── Projections ──────────────────────────────────────────────────\n\n/**\n * An aggregate projection.\n *\n * `countAll` renders `COUNT(*)`. The alias matters for portability: postgres\n * names the bare column `count`, sqlite and mysql name it `COUNT(*)` — callers\n * that must read the value back always pass an alias. Combined with a\n * non-empty `columns` list (grouped counts, `SELECT \"fk\", COUNT(*) … GROUP\n * BY \"fk\"`), it renders AFTER the columns.\n *\n * `one` renders the constant `1` — the conventional EXISTS projection; it\n * cannot be combined with a column list.\n */\nexport type SelectExpr =\n | { readonly kind: \"countAll\"; readonly alias?: string }\n | { readonly kind: \"one\" };\n\n// ─── SET operations ───────────────────────────────────────────────\n\n/** Arithmetic applied to a column's current value in an UPDATE ... SET. */\nexport type SetOperator = \"increment\" | \"decrement\" | \"multiply\" | \"divide\";\n\n/**\n * An atomic update expression: `\"col\" = \"col\" <op> $n`.\n *\n * Recognised structurally inside `UpdateStatement.set`, so the marker key is\n * deliberately unlikely (`__op`). Three layers keep a user's JSON payload from\n * ever being mistaken for one: the Json codec stringifies JSON values before\n * they reach the AST, the query builder only emits this shape for numeric\n * fields, and {@link isSetOperation} demands only the documented marker keys.\n */\nexport type SetOperation = {\n readonly __op: SetOperator;\n readonly value: number | string | bigint;\n /** Decimal arithmetic needs a REAL operand on SQLite, even for integral text. */\n readonly numericType?: \"Decimal\";\n};\n\nconst SET_OPERATORS: readonly string[] = [\"increment\", \"decrement\", \"multiply\", \"divide\"];\n\n/** Narrow an UPDATE set value to an atomic {@link SetOperation}. */\nexport function isSetOperation(value: unknown): value is SetOperation {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n const keys = Object.keys(value);\n if (!keys.includes(\"__op\") || !keys.includes(\"value\")) return false;\n const candidate = value as { __op: unknown; value: unknown; numericType?: unknown };\n if (keys.length !== 2 && !(keys.length === 3 && keys.includes(\"numericType\") && candidate.numericType === \"Decimal\")) return false;\n return (\n typeof candidate.__op === \"string\" &&\n SET_OPERATORS.includes(candidate.__op) &&\n ((typeof candidate.value === \"number\" && Number.isFinite(candidate.value)) ||\n typeof candidate.value === \"string\" || typeof candidate.value === \"bigint\")\n );\n}\n\n/**\n * A scalar-list update expression (Prisma's `{ push: … }` on list columns):\n * `append` is one element (`\"col\" = array_append(\"col\", $n)`), `concat` an\n * array of elements (`\"col\" = \"col\" || $n`). Postgres only — the query builder\n * gates on `capabilities.scalarArrays` at build time and the renderer refuses\n * too. Same structural-marker discipline as {@link SetOperation}: the key is\n * unlikely, the shape exact, and Json payloads are stringified before they\n * could ever reach an UPDATE set.\n */\nexport type ListSetOperation = {\n readonly __listOp: \"append\" | \"concat\";\n readonly value: unknown;\n};\n\nconst LIST_SET_OPERATORS: readonly string[] = [\"append\", \"concat\"];\n\n/** Narrow an UPDATE set value to a {@link ListSetOperation}. */\nexport function isListSetOperation(value: unknown): value is ListSetOperation {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n const keys = Object.keys(value);\n if (keys.length !== 2 || !keys.includes(\"__listOp\") || !keys.includes(\"value\")) return false;\n const candidate = value as { __listOp: unknown };\n return typeof candidate.__listOp === \"string\" && LIST_SET_OPERATORS.includes(candidate.__listOp);\n}\n\n/**\n * Database-clock marker: renders the DIALECT's `now()` expression — plus an\n * optional offset in seconds (fractional OK) bound as a parameter — instead of binding a\n * client-side timestamp. Flows as a VALUES cell, an UPDATE SET value, or a\n * comparison operand; the runtime's public `dbNow()` sentinel compiles to\n * this marker for DateTime fields (leases, TTLs — anything that must trust\n * the database's clock, never the process's). Same structural-marker\n * discipline as {@link SetOperation}: unlikely key, exact shape.\n */\nexport type DbNowMarker = {\n readonly __dbNow: true;\n readonly offsetSeconds: number;\n};\n\n/** Build a {@link DbNowMarker}; `offsetSeconds` is finite seconds — fractional is legal (lease TTLs arrive as ttlMs / 1000). */\nexport function dbNowMarker(params: { offsetSeconds: number }): DbNowMarker {\n return { __dbNow: true, offsetSeconds: params.offsetSeconds };\n}\n\n/** Narrow a value to a {@link DbNowMarker}. */\nexport function isDbNowMarker(value: unknown): value is DbNowMarker {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n // A-05: every object cell (each Date of a createMany) is asked; one own-key\n // test rejects them before the key list is built.\n if (!Object.hasOwn(value, \"__dbNow\")) return false;\n const keys = Object.keys(value);\n if (keys.length !== 2 || !keys.includes(\"__dbNow\") || !keys.includes(\"offsetSeconds\")) return false;\n const candidate = value as { __dbNow: unknown; offsetSeconds: unknown };\n return (\n candidate.__dbNow === true &&\n typeof candidate.offsetSeconds === \"number\" &&\n Number.isFinite(candidate.offsetSeconds)\n );\n}\n\n// ─── Ordering ─────────────────────────────────────────────────────\n\n/** ORDER BY a column, with optional NULLS placement (native or emulated per dialect). */\nexport type OrderByColumn = {\n readonly column: ColRef;\n readonly direction: \"asc\" | \"desc\";\n /** NULLS placement; rendered natively or emulated per dialect. */\n readonly nulls?: \"first\" | \"last\";\n};\n\n/** ORDER BY an aggregate expression — grouped selects ordering by `COUNT(\"col\")`. */\nexport type OrderByAggregate = {\n readonly agg: AggRef;\n readonly direction: \"asc\" | \"desc\";\n};\n\n/**\n * ORDER BY a correlated scalar subquery — relation orderBy\n * (`orderBy: { posts: { _count: \"desc\" } }` → `(SELECT COUNT(*) …)` /\n * `orderBy: { author: { email: \"asc\" } }` → `(SELECT \"email\" …)`).\n * Portable: all three dialects order by scalar subqueries. The subquery\n * correlates to the outer scope through table-qualified `cmpCol` predicates,\n * exactly like `exists`; its parameters merge into the statement's single\n * sequence in render order. NULLS placement is deliberately unsupported here\n * (emulating it would render the subquery twice and duplicate its params) —\n * missing relations sort at each engine's native NULL position.\n */\nexport type OrderBySubquery = {\n readonly select: SelectStatement;\n readonly direction: \"asc\" | \"desc\";\n};\n\nexport type OrderTerm = OrderByColumn | OrderByAggregate | OrderBySubquery;\n\n// ─── Statements ───────────────────────────────────────────────────\n\n/**\n * One `LEFT JOIN LATERAL (…) AS alias ON true` clause aggregating a correlated\n * subquery into a single JSON value per outer row — the \"join\" relation-loading\n * strategy (postgres/pglite, and MySQL 8.0.14+ since lane J; gated on\n * `capabilities.lateralJoin` and rendered through `SqlDialect.lateralJson`).\n * MySQL renders positional rows only (`JSON_ARRAY`, `JSON_ARRAYAGG`, `ON\n * true`); its aggregate cannot order, so an ordered list level carries a\n * `select.rowNumber` without partition — rendered as the row's last slot.\n *\n * Renders (agg `jsonArray`):\n * `LEFT JOIN LATERAL (SELECT COALESCE(json_agg(to_json(\"__sub\".*)), '[]'::json)\n * AS \"columnAlias\" FROM (<select>) AS \"__sub\") AS \"alias\" ON true`\n * and (agg `jsonObject`):\n * `LEFT JOIN LATERAL (SELECT to_json(\"__sub\".*) AS \"columnAlias\"\n * FROM (<select>) AS \"__sub\") AS \"alias\" ON true`\n *\n * `to_json` over a subselect (not `json_build_object`) sidesteps postgres's\n * 100-argument function limit on wide models (v1 lesson); `json` rather than\n * `jsonb` because the value is transport only — jsonb's binary build + re-\n * serialization cost 2–3.7× the server time for identical decoded values.\n * The inner select's ORDER BY drives the aggregate's element order. Consumers\n * must run the codec table over the parsed JSON children: `to_json` turns\n * timestamps into strings and loses BigInt-ness (LEARNINGS).\n */\nexport type LateralJoin = {\n /** Join alias (`__lat_0`) — the outer projection selects `alias.columnAlias`. */\n readonly alias: string;\n /** Column the aggregated JSON value is exposed under (`__rel_posts`). */\n readonly columnAlias: string;\n /** jsonArray: many rows; jsonObject: one row or NULL; count: a scalar COUNT(*) lateral. */\n readonly agg: \"jsonArray\" | \"jsonObject\" | \"count\";\n /**\n * Object output is the SQL-layer default. Positional rows follow the exact\n * select.columns order, using explicit output names (never SELECT *).\n * Above JSON_TRANSPORT.chunkSize, a row is an array of fixed-size chunks;\n * the final chunk may be shorter. Scalar/list/Json field values stay in one\n * slot. Consumers must use the SAME projection to decode the payload.\n */\n readonly rowFormat?: \"object\" | \"positional\";\n /** The correlated child select — may reference outer columns via table-qualified refs. */\n readonly select: SelectStatement;\n};\n\n/**\n * One correlated scalar `COUNT(*)` projected into a select list:\n * `(SELECT COUNT(*) FROM … WHERE <correlation>) AS \"alias\"` — the relation\n * `_count` of the round-trip campaign's R-03b, which saves the separate grouped\n * count statement. Portable: postgres, sqlite and mysql all evaluate a\n * correlated scalar subquery once per output row; the runtime wraps a paged\n * root in a derived table first, so the subqueries run only for the page.\n * The select must be ONE ungrouped `COUNT(*)` (`columns: []`, `selectExpr`\n * countAll, no grouping, paging, distinct or lock) — anything else is refused\n * at render. Its parameters join the statement's single sequence in text order\n * (the select list renders before FROM).\n */\nexport type CountSubquery = {\n /** Output column the count is exposed under (`__vibe_count_0`). */\n readonly alias: string;\n /** The correlated count select — references outer columns via table-qualified refs. */\n readonly select: SelectStatement;\n};\n\n/**\n * One `INNER JOIN \"table\" AS alias ON left = right [AND …]` clause — plain\n * equality joins only, portable across all dialects. Added for the\n * single-statement implicit-M2M load (child rows joined to their join-table\n * membership rows); extra join-table columns project through the statement's\n * `columns` list with a table qualifier + `alias`.\n */\nexport type InnerJoin = {\n readonly table: TableRef;\n /** Equality pairs ANDed into the ON clause; never empty. */\n readonly on: readonly { readonly left: ColRef; readonly right: ColRef }[];\n};\n\n// ─── Fix lane Q2 (D-03): derived-table LEFT JOIN ───\n\n/**\n * One `LEFT JOIN (<select>) AS \"alias\" ON \"alias\".\"k\" = \"outer\".\"c\" [AND …]`\n * clause — portable, equality ON pairs only. Built for the to-one relation\n * `orderBy` (`orderBy: { author: { email: \"asc\" } }`): the target's key and\n * sort columns ride a derived table under RESERVED aliases (`__vibe_ok0`,\n * `__vibe_ov0`), so the outer statement's unqualified column names can never\n * become ambiguous, and the outer ORDER BY names `\"alias\".\"__vibe_ov0\"`.\n * Every engine merges such a derived table into a plain join (measured:\n * postgres pulls it up into a hash/nested-loop left join, sqlite flattens it,\n * mysql merges it), so the planner may hash-join instead of evaluating a\n * correlated subquery per candidate row.\n *\n * The builder emits it only for links that match AT MOST ONE target row, so\n * the join keeps the parent row count. The derived select must alias every\n * projected column; its parameters (none today) join the statement's single\n * sequence where the clause renders (after `keyTable`, before\n * `lateralJoins`). A statement with a `rowLock` refuses it: postgres rejects\n * FOR UPDATE on the nullable side of an outer join, and mysql would lock the\n * joined rows too.\n */\nexport type LeftJoin = {\n /** Derived-table alias (`__ord1`). */\n readonly alias: string;\n /** The derived table — every projected column carries an `alias`. */\n readonly select: SelectStatement;\n /** Equality pairs ANDed into the ON clause; never empty. */\n readonly on: readonly { readonly left: ColRef; readonly right: ColRef }[];\n};\n\n/**\n * How one member of a {@link KeyTableJoin} tuple binds inside the derived\n * table. `value` binds the parameter as it is: it stays COERCIBLE, so a text\n * column's OWN collation decides `=` — the equality `col IN (?, …)` uses.\n * `integer` and `decimal` cast the parameter into the column's numeric family:\n * BigInt and Decimal values travel as strings, and a derived-table string\n * compared with a numeric column goes through a double (measured on mysql:\n * `9007199254740993` matched `9007199254740992`).\n *\n * `integer` renders `CAST(? AS SIGNED)`. `decimal` renders\n * `CAST(? AS DECIMAL(65, scale))` with the tested column's own scale: 65 is\n * MySQL's maximum precision, so the cast holds every value a\n * `DECIMAL(p, scale)` column can hold. A fixed `DECIMAL(65,30)` held only 35\n * integer digits and clipped a `Decimal(65, 0)` key onto its maximum, which\n * matched nothing (review finding 1); the column's own precision would clip a\n * wider value onto the column's maximum and pair it with a row it does not\n * equal (measured: `CAST('100000' AS DECIMAL(5,0))` is `99999`). `scale` is\n * 0–30, MySQL's range.\n *\n * `citext` (postgres only) renders `CAST($n AS citext)`: a postgres `citext`\n * key compares case-insensitively, and a bare VALUES parameter would be\n * `text`, whose `=` against a citext column is the case-sensitive text\n * operator. A VALUES cell has no column to infer a type from, so every member\n * of a postgres key table binds typed: `citext`, `text` (`CAST($n AS text)`,\n * a text or varchar column) or `integer` (`CAST($n AS bigint)`, exact against\n * any integer column) — any other member refuses on postgres. `text` is\n * postgres-only; mysql binds text members as `value`.\n */\nexport type KeyTableMember =\n | { readonly kind: \"value\" }\n | { readonly kind: \"integer\" }\n | { readonly kind: \"decimal\"; readonly scale: number }\n /** MySQL-only lossless temporal operands in mixed collation-aware key tuples. */\n | { readonly kind: \"timestamp\" }\n | { readonly kind: \"time\" }\n | { readonly kind: \"citext\" }\n | { readonly kind: \"text\" };\n\n/**\n * The batch's key tuples as a derived table, each tagged with its ORDINAL\n * (row `i` carries `i`), INNER JOINed on the tested columns — mysql:\n * `INNER JOIN (VALUES ROW(?, 0), ROW(?, 1)) AS \\`alias\\` (\\`__vibe_k0\\`, \\`ordinal\\`)\n * ON col = \\`alias\\`.\\`__vibe_k0\\``; postgres only over `citext` members\n * (`(VALUES (CAST($1 AS citext), 0), …)`, release 3.0 nested writes).\n * Member columns are named `__vibe_k<i>` (a reserved prefix, so unqualified\n * child columns never collide with them).\n *\n * Why it exists (EPIC R): a relation load used to stitch children to parents\n * by comparing decoded keys in JavaScript, while mysql's collations equate\n * spellings (`acme` = `Acme` = `ACME`, `cafe` = `Café`, `x ` = `x`) that\n * JavaScript keeps apart — the foreign key and the `IN` filter accepted the\n * child, the stitch dropped it. Joined this way the DATABASE pairs every child\n * row with every batch key it considers equal, and the projected ordinal names\n * the key; the join is also the membership filter.\n */\nexport type KeyTableJoin = {\n /** Derived-table alias (`__vibe_keys`); the ordinal projects as `alias.ordinalAlias`. */\n readonly alias: string;\n /** The statement's columns, compared member by member (`=`), in tuple order. */\n readonly columns: readonly ColRef[];\n /** How each member binds, in tuple order — see {@link KeyTableMember}. */\n readonly members: readonly KeyTableMember[];\n /** Encoded key tuples; never empty, each as long as `columns`. */\n readonly rows: readonly (readonly unknown[])[];\n /** Output name of the ordinal column. */\n readonly ordinalAlias: string;\n};\n\n/**\n * A `ROW_NUMBER() OVER (PARTITION BY … [ORDER BY …]) AS \"alias\"` projection,\n * appended after `columns` — the distinct emulation on dialects without\n * `DISTINCT ON` (sqlite ≥3.25, mysql ≥8.0 both have window functions): the\n * outer statement filters `alias = 1` on the derived table, restoring\n * SQL-side take/skip and bounded transfer (N10).\n */\nexport type RowNumberProjection = {\n readonly partitionBy: readonly ColRef[];\n /** Intra-partition order picking the representative row; may be empty. */\n readonly orderBy: readonly OrderTerm[];\n readonly alias: string;\n};\n\n// ─── Fix lane Q1 (round 3, DB-01): per-key page ──────────────────\n\n/**\n * A PER-KEY PAGE of one child table as a derived-table FROM\n * (`SelectStatement.keyPage`): for every listed key tuple, the child rows\n * whose key columns equal it, ordered by `select.orderBy` and cut by\n * `select.limit`/`select.offset` — each key's OWN page, plus a rank column\n * (`rankAlias`) that orders the rows inside their key. The paged include's\n * `ROW_NUMBER() OVER (PARTITION BY key …)` window returns the same rows but\n * numbers EVERY child of every listed key first; this form reads one page of\n * primary keys per key through an index on (key columns, order columns),\n * then each page row once by its primary key.\n *\n * Rendered per `SqlDialect.keyPageStrategy`:\n * - `lateral` (postgres): `unnest($1::<type>[], …) AS \"__vibe_keys\"\n * (\"__vibe_k0\", …) CROSS JOIN LATERAL (SELECT <identity>, ROW_NUMBER() OVER\n * (PARTITION BY <key> ORDER BY <order>) AS <rank> FROM <table> WHERE <key> =\n * \"__vibe_keys\".\"__vibe_k<i>\" … ORDER BY <order> LIMIT … OFFSET …) AS\n * \"__vibe_ids\" INNER JOIN <table> AS \"__vibe_page\" ON <identity> pairs`.\n * - `inLimit` (sqlite, which has no LATERAL): the key tuples as `(VALUES …)`\n * (columns `column1`, `column2`, …, as SQLite names a VALUES clause's\n * columns) joined to `<table> AS \"__vibe_page\"` ON `(<identity>) IN (SELECT\n * <identity> … WHERE <key> = \"__vibe_keys\".\"column<i>\" … ORDER BY … LIMIT …)`,\n * the rank re-derived over the fetched page (`ROW_NUMBER() OVER (PARTITION\n * BY <key> ORDER BY <order>)`): its values differ from the window's, its\n * order inside a key does not.\n * - `window` (mysql): refused with `VIBE_UNSUPPORTED_CAPABILITY` — measured\n * no gain there; the runtime keeps the window.\n *\n * The caller guarantees what makes the page equal to the window's: the order\n * is total inside a key (the identity columns are among the key and order\n * columns), the key tuples are distinct and compare exactly (no folding\n * collation). Members bind like the key-list filter's (`KeyListMember`).\n */\nexport type KeyPage = {\n /** How each key member binds, in member order (postgres: one typed array each). */\n readonly members: readonly KeyListMember[];\n /** Encoded, distinct key tuples; never empty, each `members.length` long. */\n readonly rows: readonly (readonly unknown[])[];\n /** The child columns each key member equals, in member order (unqualified). */\n readonly keyColumns: readonly ColRef[];\n /** The child's primary-key columns (unqualified) — each page row is read once by them. */\n readonly identity: readonly ColRef[];\n /**\n * ONE key's page: the child `table` (no alias), the projected `columns`\n * (unqualified; transforms and aliases render as usual), an optional extra\n * `where`, the non-empty `orderBy` (plain column terms), `limit`/`offset`.\n * Any other member is refused.\n */\n readonly select: SelectStatement;\n /** Output name of the rank column. */\n readonly rankAlias: string;\n};\n\n/**\n * Statement-count pass EPIC 4 (round-3 ST-07): bound key tuples as the FROM\n * of a select (`SelectStatement.fromKeys`) — a derived table named\n * `table.name` whose columns are `columns`, one row per tuple. The write\n * follow-up puts it where the parent table would be: the find path's laterals\n * correlate to `\"<table.name>\".\"<column>\"` exactly as over the table, but read\n * the RETURNED key values instead of the parent row (a deleted row, or a\n * native-RLS parent whose SELECT policy the per-relation loads never met).\n *\n * Renders where `SqlDialect.keyListStrategy` is `unnest` (postgres) as the\n * typed form of a `VALUES` list — one array per column, typed like the\n * key-list filter's members (`postgresKeyListElementType`), so the text does\n * not depend on the tuple count: `FROM unnest($1::text[], $2::int4[]) AS\n * \"Post\" (\"id\", \"authorId\")`. A `DateTime` member without a declared native\n * type (`keyListBindsUntypedRows`) and every other dialect refuse with\n * `VIBE_UNSUPPORTED_CAPABILITY` — those dialects have no lateral joins either.\n */\nexport type KeyRows = {\n /** Output column names of the derived table, in member order. */\n readonly columns: readonly string[];\n /** How each column binds, in column order — see {@link KeyListMember}. */\n readonly members: readonly KeyListMember[];\n /** Encoded tuples; never empty, each exactly `columns.length` long. */\n readonly rows: readonly (readonly unknown[])[];\n};\n\nexport type SelectStatement = {\n readonly kind: \"select\";\n readonly table: TableRef;\n /** Empty array renders as `SELECT *` (unless `selectExpr` replaces it). */\n readonly columns: readonly ColRef[];\n /**\n * Aggregate projection. Replaces the column list when `columns` is empty;\n * a `countAll` with columns renders after them (grouped counts).\n */\n readonly selectExpr?: SelectExpr;\n /**\n * Aliased aggregate projections (`AVG(\"col\") AS \"_avg__col\"`), rendered\n * after `columns` — the aggregate/groupBy/count-select shapes. Cannot be\n * combined with `selectExpr`.\n */\n readonly aggregates?: readonly AggSelect[];\n /** Correlated `COUNT(*)` subqueries, rendered after `aggregates` — see {@link CountSubquery}. */\n readonly countSubqueries?: readonly CountSubquery[];\n /**\n * `SELECT DISTINCT ON (cols)` — postgres only (`capabilities.distinctOn`;\n * other dialects refuse at render time and the runtime emulates client-side\n * instead). ORDER BY must lead with these columns; the query builder\n * guarantees that arrangement.\n */\n readonly distinctOn?: readonly ColRef[];\n /**\n * Plain `SELECT DISTINCT` over the whole projection — every dialect. The\n * query builder sets it only where it returns exactly the rows its\n * `ROW_NUMBER()` distinct emulation would (sqlite/mysql, value-exact keys,\n * projection equal to the distinct fields); never together with\n * `distinctOn` (the renderer refuses the pair).\n */\n readonly distinct?: true;\n /**\n * Derived-table FROM: renders `FROM (<fromSelect>) AS \"<table.name>\"` —\n * `table.name` is the subquery ALIAS and `table.alias` must be unset. Used\n * by aggregate-over-a-subset shapes (`aggregate({ take, skip, orderBy })`).\n */\n readonly fromSelect?: SelectStatement;\n /** Lateral JSON-aggregation joins — postgres and MySQL 8.0.14+, see {@link LateralJoin}. */\n readonly lateralJoins?: readonly LateralJoin[];\n /** Plain equality INNER JOINs — portable, see {@link InnerJoin}. */\n readonly innerJoins?: readonly InnerJoin[];\n /** Key-table join, rendered after `innerJoins` — mysql only, see {@link KeyTableJoin}. */\n readonly keyTable?: KeyTableJoin;\n /** Fix lane Q2 (D-03): derived-table LEFT JOINs, rendered after `keyTable` — see {@link LeftJoin}. */\n readonly leftJoins?: readonly LeftJoin[];\n /** ROW_NUMBER window projection — see {@link RowNumberProjection}. */\n readonly rowNumber?: RowNumberProjection;\n /**\n * Fix lane Q1 (DB-01): derived-table FROM over a per-key page — renders\n * `FROM (<per-key page>) AS \"<table.name>\"` like `fromSelect` (and never\n * together with it); see {@link KeyPage}.\n */\n readonly keyPage?: KeyPage;\n /**\n * Fix lane Q2 (round 3, DB-07): derived-table FROM over a `UNION ALL` of\n * branch selects — renders `FROM (SELECT * FROM (<branch 0>) AS\n * \"__vibe_u0\" UNION ALL SELECT * FROM (<branch 1>) AS \"__vibe_u1\" …) AS\n * \"<table.name>\"`. Each branch keeps its own ORDER BY and LIMIT: wrapped in\n * its own derived table, a limited branch is valid on all three engines\n * (SQLite refuses ORDER BY/LIMIT on a bare compound member). At least two\n * branches; each a plain `SELECT <columns> FROM <table> [WHERE] [ORDER BY]\n * [LIMIT]` projecting the same output names in the same order; never\n * together with `fromSelect`, `keyPage` or a `table.alias`. Parameters bind\n * branch by branch, in text order.\n */\n readonly fromUnion?: readonly SelectStatement[];\n /**\n * Statement-count pass EPIC 4 (ST-07): derived-table FROM over bound key\n * tuples, named `table.name` with the listed column names — see\n * {@link KeyRows}. Never together with `fromSelect`, `keyPage`, `fromUnion`,\n * a `table.alias` or a `rowLock`.\n */\n readonly fromKeys?: KeyRows;\n readonly where?: SqlExpr;\n readonly groupBy?: readonly ColRef[];\n /** HAVING predicate — grouped selects; may contain `aggCmp` expressions. */\n readonly having?: SqlExpr;\n readonly orderBy?: readonly OrderTerm[];\n readonly limit?: number;\n readonly offset?: number;\n /**\n * Row-locking read (`SELECT … FOR UPDATE SKIP LOCKED`) — see {@link RowLock}.\n * The internal read-before-write overlays (dialects without RETURNING) set\n * the plain `{ strength: \"update\", wait: \"wait\" }` lock. Rendered only where\n * the dialect names the clause (`dialect.rowLockSyntax`); sqlite has none and\n * needs none — its write transactions already exclude each other.\n */\n readonly rowLock?: RowLock;\n};\n\n/**\n * The lock a locking read takes: one strength, one wait policy. Both members\n * are REQUIRED here — defaulting happens once, in the query builder, so the\n * rendered SQL is a function of the AST alone.\n */\nexport type RowLock = {\n readonly strength: RowLockStrength;\n readonly wait: RowLockWaitPolicy;\n};\n\n/**\n * Sentinel VALUES cell: render the `DEFAULT` keyword instead of a placeholder\n * (M4) — a heterogeneous createMany row that omits a field lets the COLUMN\n * default apply (or NULL on a defaultless nullable column), exactly like a\n * single-row insert that omits it. Postgres/mysql only\n * (`dialect.rowDefaultKeyword`); sqlite groups rows instead.\n */\nexport const SQL_DEFAULT_CELL: { readonly __sqlDefault: true } = Object.freeze({ __sqlDefault: true });\n\n/**\n * Sentinel update-arm cell: the column keeps its current value —\n * `` `col` = `table`.`col` `` (V8, the insert-if-missing upsert). Valid only in\n * an {@link OnConflictUpdate} `update` set, where MySQL's `ON DUPLICATE KEY\n * UPDATE` needs at least one assignment: a self-assignment changes nothing on a\n * duplicate and, unlike `INSERT IGNORE`, leaves every other error an error.\n * Refused in a plain UPDATE's SET list.\n */\nexport const SQL_KEEP_CELL: { readonly __sqlKeep: true } = Object.freeze({ __sqlKeep: true });\n\n/** Is this update cell the {@link SQL_KEEP_CELL} sentinel? */\nexport function isSqlKeepCell(value: unknown): boolean {\n return value === SQL_KEEP_CELL;\n}\n\n/** Is this VALUES cell the {@link SQL_DEFAULT_CELL} sentinel? */\nexport function isSqlDefaultCell(value: unknown): boolean {\n return value === SQL_DEFAULT_CELL;\n}\n\n/**\n * VALUES/SET cell carrying a Json column's parameter (the codec's JSON text).\n *\n * Why it exists: OID-typed drivers (bun:sql) resolve each parameter's postgres\n * type and re-serialize the JS value AS that type — a pre-stringified Json\n * param bound straight into a bare jsonb slot arrives DOUBLE-ENCODED (a jsonb\n * string holding the document; live-proven on Bun 1.3.14). The postgres\n * renderer pins the parameter's type instead (`$n::text::jsonb`,\n * `SqlDialect.jsonParamCast`), so every driver sends the text through and the\n * SERVER parses it; text-param drivers (node-postgres, pglite) are unaffected.\n * Sqlite/mysql render the bare placeholder — their Json transport is already\n * plain text. The COLLECTED parameter is the plain text either way: this\n * wrapper never crosses the wire.\n *\n * `storage: \"json\"` marks a postgres `json` column (`Json @db.Json`): the cell\n * renders `$n::text::json`, so the column stores the text as written (key\n * order and spelling kept) instead of jsonb's normalized text (release-3.0\n * D3). Absent = jsonb; dialects without a param cast ignore it.\n */\nexport type JsonParamCell = { readonly __jsonParam: true; readonly text: string; readonly storage?: \"json\" };\n\n/** Wrap a Json column's encoded (stringified) parameter for cast-site rendering. */\nexport function jsonParamCell(params: { text: string; storage?: \"json\" }): JsonParamCell {\n return params.storage === \"json\" ? { __jsonParam: true, text: params.text, storage: \"json\" } : { __jsonParam: true, text: params.text };\n}\n\n/** Is this VALUES/SET cell a {@link JsonParamCell}? */\nexport function isJsonParamCell(value: unknown): value is JsonParamCell {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __jsonParam?: unknown }).__jsonParam === true\n );\n}\n\n/**\n * Reference to the row PROPOSED for insertion, inside an upsert's update arm:\n * `excluded.\"col\"` on postgres/sqlite, `` `new`.`col` `` on mysql's row-alias\n * form (`SqlDialect.excludedRowRef`). It is a COLUMN REFERENCE, not a\n * parameter — it names the value already bound in this statement's VALUES\n * list, which is what lets ONE batched upsert write each conflicting row's own\n * incoming values without binding them a second time.\n */\nexport type ExcludedRef = { readonly __excluded: true; readonly column: string };\n\n/** Reference the incoming row's `column` from inside an upsert update arm. */\nexport function excludedRef(params: { column: string }): ExcludedRef {\n return { __excluded: true, column: params.column };\n}\n\n/** Is this SET cell an {@link ExcludedRef}? */\nexport function isExcludedRef(value: unknown): value is ExcludedRef {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __excluded?: unknown }).__excluded === true\n );\n}\n\n/**\n * One RETURNING column: a bare column name renders `\"col\"`; `castText` renders\n * a dialect text cast (postgres `::text`, sqlite `CAST AS TEXT`) for lossless\n * transport, including timestamps and postgres arrays. `jsonText`\n * applies the dialect's JSON text projection, as {@link ColRef.transform} does\n * for SELECT. Dialects without RETURNING still omit the clause and flag it.\n */\nexport type ReturningColumn =\n | string\n | { readonly name: string; readonly castText: true }\n | { readonly name: string; readonly transform: \"jsonText\" };\n\n/** The column name a {@link ReturningColumn} exposes in the result row. */\nexport function returningColumnName(column: ReturningColumn): string {\n return typeof column === \"string\" ? column : column.name;\n}\n\nexport type InsertStatement = {\n readonly kind: \"insert\";\n readonly table: TableRef;\n readonly columns: readonly string[];\n /** Row values aligned to `columns` — deterministic parameter order. */\n readonly rows: readonly (readonly unknown[])[];\n /** Upsert clause: ON CONFLICT (pg/sqlite) or ON DUPLICATE KEY (mysql). */\n readonly onConflict?: OnConflictClause;\n /** Rendered as RETURNING where the dialect supports it, else omitted+flagged. */\n readonly returning?: readonly ReturningColumn[];\n /**\n * Bind the rows as ONE typed array per column instead of one parameter per\n * value (`SqlDialect.bulkInsertForm` `\"unnest\"`, postgres): `INSERT INTO t\n * (\"a\", \"b\") SELECT \"c1\", \"c2\" FROM unnest($1::text[], $2::int4[]) WITH\n * ORDINALITY AS \"__vibe_rows\" (\"c1\", \"c2\", \"ord\") ORDER BY \"ord\"`. The text\n * is the same for 2 rows and for 3 000, and the statement binds one parameter\n * per column. `ORDER BY \"ord\"` keeps input order (sequence values, the\n * `ON CONFLICT DO NOTHING` winner).\n *\n * One entry per column, in `columns` order: the column's DECLARED type facts\n * (see {@link KeyListMember}; a `Json` entry names its storage through\n * `nativeType`). Each array binds the BASE type (`varchar`, never\n * `varchar(191)` — an explicit modifier cast truncates silently), so the\n * INSERT's own assignment applies the column's length and precision exactly\n * as it does for a VALUES parameter. `rows` stays row-major: the renderer\n * transposes it. Every cell is a plain value, SQL NULL or a\n * {@link JsonParamCell} — never `DEFAULT` or the database clock (the query\n * builder keeps VALUES for those; the renderer refuses them).\n */\n readonly unnest?: readonly KeyListMember[];\n};\n\n/** Conflicting rows are updated with these column values. */\nexport type OnConflictUpdate = {\n /** Conflict target columns (ignored by the mysql form). */\n readonly columns: readonly string[];\n /**\n * Named-constraint target: `ON CONFLICT ON CONSTRAINT \"name\" DO UPDATE`.\n * Postgres only; replaces the column-list target when present.\n */\n readonly constraint?: string;\n /**\n * Partial-index arbiter predicate, RAW SQL: `ON CONFLICT (cols) WHERE pred\n * DO UPDATE …` (postgres/sqlite; requires `columns`). Raw for the same\n * reason {@link OnConflictDoNothing.conflictWhere} is — both engines match\n * the clause against the index's OWN stored predicate structurally, so a\n * bound parameter could never match and the text mirrors the schema\n * declaration byte-for-byte. Mysql's ODKU names no target and refuses it.\n */\n readonly conflictWhere?: string;\n readonly update: Readonly<Record<string, unknown>>;\n /**\n * MySQL only (`upsertForm: \"onDuplicateKey\"`): append\n * `` `col` = LAST_INSERT_ID(`col`) `` to the update list so the UPDATE arm\n * records the addressed row's key — without it `LAST_INSERT_ID()` is stale\n * on the update arm and the read-back can resolve a wrong, unrelated row\n * (SQL review B2, live-proven on 8.4). Only meaningful for integer keys.\n */\n readonly lastInsertIdColumn?: string;\n};\n\n/**\n * Conflicting rows are skipped (`createMany({ skipDuplicates: true })`).\n * An empty/absent target means \"any conflict\" — the mysql form\n * (`ON DUPLICATE KEY UPDATE k = t.k`, dialect `doNothingForm:\n * \"duplicateKeyKeep\"`) can only express that, so it ignores a bare `columns`\n * target (documented degradation) and REFUSES the refined targets below.\n */\nexport type OnConflictDoNothing = {\n /**\n * MySQL form only (`duplicateKeyKeep`): the column the duplicate arm assigns\n * to itself (`` `k` = `t`.`k` ``, a no-op). Absent = the first inserted\n * column; an all-default row (no column) must name one.\n */\n readonly keepColumn?: string;\n /**\n * MySQL form only, single-row statements: a decimal literal S (digits only).\n * The keep assignment becomes `` `k` = IF(LAST_INSERT_ID(S), `t`.`k`, `t`.`k`) ``,\n * so a skipped duplicate reports S as the statement's insert id (an inserted\n * row reports its own id, or 0) — the exact skipped verdict that the\n * affected count cannot give with CLIENT_FOUND_ROWS (an unchanged duplicate\n * counts 1, like an insert). The builder picks S unequal to the row's\n * explicit AUTO_INCREMENT value.\n */\n readonly duplicateFlag?: string;\n readonly columns?: readonly string[];\n /**\n * Partial-index target predicate, RAW SQL: `ON CONFLICT (cols) WHERE pred\n * DO NOTHING` (postgres/sqlite; requires `columns`). Raw — and rendered\n * verbatim — because BOTH engines match the clause against the index's OWN\n * stored predicate structurally: a bound parameter could never match, so\n * the text mirrors the schema declaration's `where:` string byte-for-byte.\n */\n readonly conflictWhere?: string;\n /** Named-constraint target (`ON CONSTRAINT \"name\"`) — postgres only. */\n readonly constraint?: string;\n readonly doNothing: true;\n};\n\nexport type OnConflictClause = OnConflictUpdate | OnConflictDoNothing;\n\nexport type UpdateStatement = {\n readonly kind: \"update\";\n readonly table: TableRef;\n /**\n * Column → parameter value, or an atomic {@link SetOperation}. As a\n * {@link ChainStep} only (statement-maxx lane C3), a value may be a\n * {@link StepColumnRef} to an EARLIER step: `\"col\" = (SELECT \"c\" FROM\n * \"step\")` — the step must return at most one row (an owner resolved by a\n * unique where, or an owner INSERT of one row).\n */\n readonly set: Readonly<Record<string, unknown>>;\n readonly where?: SqlExpr;\n readonly returning?: readonly ReturningColumn[];\n};\n\nexport type DeleteStatement = {\n readonly kind: \"delete\";\n readonly table: TableRef;\n readonly where?: SqlExpr;\n readonly returning?: readonly ReturningColumn[];\n};\n\n/** Native RLS DDL, kept distinct from ordinary row-query expressions. */\nexport type RlsEnableStatement = { readonly kind: \"rlsEnable\"; readonly table: string };\nexport type RlsForceStatement = { readonly kind: \"rlsForce\"; readonly table: string };\n/** Disable native row policy enforcement on a physical table. */\nexport type RlsDisableStatement = { readonly kind: \"rlsDisable\"; readonly table: string };\n/** Remove forced owner enforcement on a physical table. */\nexport type RlsNoForceStatement = { readonly kind: \"rlsNoForce\"; readonly table: string };\n/** Drop the managed policy by default, or the supplied policy name. */\nexport type RlsDropPolicyStatement = { readonly kind: \"rlsDropPolicy\"; readonly table: string; readonly policyName?: string };\nexport type RlsPolicyStatement = {\n readonly kind: \"rlsPolicy\";\n readonly schema: SchemaIR;\n readonly model: string;\n /** Probe policies use a distinct identity without changing the predicate. */\n readonly policyName?: string;\n /** Only the probe target may be temporary; parent relations always remain public. */\n readonly targetSchema?: \"public\" | \"pg_temp\";\n};\n\n/** Values are validated/serialized by runtime; null is the absent setting sentinel. */\nexport type RlsContextStatement = {\n readonly kind: \"rlsContext\";\n readonly context: RlsContextIR;\n readonly values: Readonly<Record<string, string | null>>;\n /** PGlite: bind this trusted runtime role first, in the same statement. */\n readonly role?: string;\n /** Switch the transaction to READ ONLY in the same statement, after the claims. */\n readonly readOnly?: boolean;\n /** Report the backend as `\"backendPid\"` / `\"backendStart\"` text columns. */\n readonly backend?: boolean;\n};\n\n/** Trusted pre-existing PGlite execution role; never a request-supplied principal. */\nexport type RlsRoleStatement = { readonly kind: \"rlsRole\"; readonly role: string };\n\n// ─── Advisory locks ───────────────────────────────────────────────\n\n/**\n * An advisory lock's key: a lock space the APPLICATION defines, so a resource\n * with no row of its own can still be locked.\n *\n * Two forms, exactly as PostgreSQL offers them, and they are DIFFERENT lock\n * spaces — holding `{ classId: 11, objectId: 22 }` does not block the single\n * key `11 * 2^32 + 22` (probe-verified on PostgreSQL 18.6). Pick one form per\n * resource family and stay in it.\n */\nexport type AdvisoryLockKey =\n | { readonly key: bigint }\n | { readonly classId: number; readonly objectId: number };\n\n/**\n * Take a TRANSACTION-scoped advisory lock. Released by commit and by rollback\n * (including `ROLLBACK TO SAVEPOINT` when it was taken after the savepoint —\n * probe-verified), never by an explicit unlock call, so no leak can outlive the\n * transaction on a pooled connection.\n *\n * `wait: \"nowait\"` renders the `pg_try_advisory_xact_lock*` family, whose single\n * boolean column says whether the lock was taken; `\"wait\"` renders the blocking\n * family, which returns void.\n */\nexport type AdvisoryLockStatement = {\n readonly kind: \"advisoryLock\";\n readonly mode: AdvisoryLockMode;\n readonly wait: \"wait\" | \"nowait\";\n readonly key: AdvisoryLockKey;\n};\n\n/** The column an advisory try-lock projects its verdict into. */\nexport const ADVISORY_LOCK_RESULT_COLUMN: string = \"acquired\";\n\n// ─── Statement chains ────────────────────────────────────────────────\n\n/**\n * A cell of an {@link InsertSelectStatement} that reads a column of an EARLIER\n * chain step: `\"step\".\"column\"`. A column reference, not a parameter — the\n * value comes from the step's rows inside the same statement (a child row\n * taking its parent's key from the parent step, round-trip campaign EPIC F).\n * The step must be named in the insert's `from` list.\n */\nexport type StepColumnRef = { readonly __stepColumn: true; readonly step: string; readonly column: string };\n\n/** Reference `column` of the earlier chain step `step` from an INSERT … SELECT cell. */\nexport function stepColumnRef(params: { step: string; column: string }): StepColumnRef {\n return { __stepColumn: true, step: params.step, column: params.column };\n}\n\n/** Is this INSERT … SELECT cell a {@link StepColumnRef}? */\nexport function isStepColumnRef(value: unknown): value is StepColumnRef {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __stepColumn?: unknown }).__stepColumn === true\n );\n}\n\n/**\n * `INSERT INTO t (cols) SELECT <cells> [FROM \"step\", …] [WHERE <expr>]\n * [RETURNING …]` — an INSERT whose ONE row is a SELECT list instead of a\n * VALUES row, so a WHERE can veto the write inside the statement and cells can\n * read earlier steps. Valid ONLY as a {@link ChainStep} statement.\n *\n * Cells take the same forms as a VALUES cell — a codec-encoded value, a\n * {@link JsonParamCell}, a {@link DbNowMarker} — plus {@link StepColumnRef}.\n * The {@link SQL_DEFAULT_CELL} is refused: `DEFAULT` is not allowed in a SELECT\n * list; an omitted column takes its default by being absent from `columns`.\n *\n * Parameter typing (O-03, probed on PostgreSQL): a bare parameter in this\n * one-row SELECT list takes the TARGET column's type, exactly as in VALUES.\n */\nexport type InsertSelectStatement = {\n readonly kind: \"insertSelect\";\n readonly table: TableRef;\n readonly columns: readonly string[];\n /** One cell per column, aligned to `columns` — deterministic parameter order. */\n readonly cells: readonly unknown[];\n /** Earlier chain steps the SELECT reads FROM, in order (absent: a one-row SELECT without FROM). */\n readonly from?: readonly string[];\n /**\n * Several source rows (round-trip campaign EPIC F): the SELECT reads them\n * from a derived table `alias`, joined after the `from` steps, and the\n * `cells` read its columns through `stepColumnRef({ step: alias, column })`.\n * See {@link ChainRowSource} for how the rows are typed.\n */\n readonly source?: ChainRowSource;\n readonly where?: SqlExpr;\n /**\n * `ON CONFLICT (<columns>) DO NOTHING` (statement-maxx lane C2): a row whose\n * conflict target already exists is skipped and not returned — the implicit\n * many-to-many join INSERT, where re-connecting an existing pair is a no-op.\n * Postgres form only (the chain renders nowhere else); at least one column.\n */\n readonly conflictDoNothing?: { readonly columns: readonly string[] };\n readonly returning?: readonly ReturningColumn[];\n};\n\n/**\n * Rows an {@link InsertSelectStatement} inserts, as ONE derived table:\n * `(SELECT <cols> FROM (VALUES (<typed NULL row>), ($1, $2), …) AS \"alias\"\n * (<cols>) OFFSET 1) AS \"alias\"`.\n *\n * Why the typed NULL row (review O-03): a bare parameter outside the INSERT's\n * own VALUES has no type, and PostgreSQL resolves an all-parameter column of a\n * VALUES list or UNION in FROM as `text` (\"column is of type integer but\n * expression is of type text\"). The first row is one `(SELECT \"col\" FROM\n * <typedBy> WHERE FALSE)` per column — a NULL of the TARGET column's exact\n * type (enums, `numeric(p,s)`, `varchar(n)`, domains and arrays included) —\n * so every parameter below takes that type, with no cast map anywhere;\n * `OFFSET 1` drops the row. (A `UNION ALL` of one-row SELECTs types the same\n * way but costs ~10× the planning time at 1000 rows — EPIC F shape gate.)\n *\n * Cells take the VALUES forms: a codec-encoded value, a {@link JsonParamCell}\n * or a {@link DbNowMarker}; the DEFAULT cell is refused (a homogeneous row set\n * omits the column instead). A cell carrying its OWN type (the Json cast, the\n * clock) must agree with the column's type under VALUES' common-type rules,\n * which are stricter than INSERT's assignment casts — the builder keeps such\n * columns out (EPIC F eligibility). Rows are read in list order, which is the\n * order the INSERT consumes them.\n */\nexport type ChainRowSource = {\n readonly alias: string;\n /** The table whose columns type the rows — normally the INSERT's own table. */\n readonly typedBy: TableRef;\n readonly columns: readonly string[];\n /** At least one row, each aligned to `columns`. */\n readonly rows: readonly (readonly unknown[])[];\n};\n\n/** What one chain step may be: a read, or a data-modifying statement with RETURNING. */\nexport type ChainStepStatement =\n | SelectStatement\n | InsertStatement\n | InsertSelectStatement\n | UpdateStatement\n | DeleteStatement;\n\n/**\n * One named step: rendered `\"name\" AS (<statement>)`. Later steps and the\n * result read it as a table (`FROM \"name\"`, `EXISTS (SELECT 1 FROM \"name\" …)`,\n * a {@link StepColumnRef}). A data-modifying step contributes the rows its\n * RETURNING list names.\n */\nexport type ChainStep = {\n readonly name: string;\n readonly statement: ChainStepStatement;\n};\n\n/**\n * The chain's final SELECT: the rows of `rowsFrom` (in that order, `UNION\n * ALL`), each projecting `columns`.\n *\n * `verdict` adds one column `alias` = `expr` to every row, AND guarantees a\n * row: when the `rowsFrom` steps return nothing, the result is exactly ONE\n * verdict row whose `columns` are all NULL. A caller recognizes it by NULL in\n * a column the steps never return as NULL (a primary key). Accounting\n * consequence: such a statement returns one row per written row OR one\n * verdict row — a caller that counts returned rows as row changes must undo a\n * verdict-row outcome (the upsert fold always rolls it back).\n */\nexport type ChainResult = {\n readonly rowsFrom: readonly string[];\n readonly columns: readonly string[];\n readonly verdict?: { readonly alias: string; readonly expr: SqlExpr };\n /**\n * In-statement vetoes (round-trip campaign EPIC F), checked in order: when\n * `step` returned no row (fewer than `minRows`, EPIC W), the STATEMENT FAILS — so the database undoes every\n * effect of every step, trigger writes included — with an error whose\n * message carries `__vibe_veto:<token>:<nonce>:` ({@link CHAIN_VETO_PREFIX},\n * {@link chainVetoToken}). Requires `tally`: the veto is the tally column's\n * guard, so it is evaluated exactly once, on the one guaranteed result row.\n */\n readonly veto?: readonly ChainVeto[];\n /**\n * One column `alias` on every result row: the number of rows the listed\n * data-modifying steps returned (their RETURNING rows = their direct\n * effects). Guarantees one row like `verdict`. Row-change accounting reads\n * it instead of counting result rows (effect `writeTally`).\n */\n readonly tally?: ChainTally;\n};\n\n/**\n * Fail the statement when `step` returned no row; `token` names the veto in the\n * error. `nonce` is bound as a PARAMETER into the marker (never SQL text): a\n * per-call random value the caller requires back in the error, so a user value\n * that merely looks like a marker is never read as a veto.\n *\n * `minRows` (EPIC W) makes the veto count-sensitive: the statement fails when\n * `step` returned FEWER rows than that (a multi-row INSERT a trigger shortened).\n * Omitted or 1 = \"no row\". A positive safe integer, rendered as SQL text.\n */\nexport type ChainVeto = { readonly step: string; readonly token: string; readonly nonce: string; readonly minRows?: number };\n\n/** Count the RETURNING rows of `steps` into the result column `alias`. */\nexport type ChainTally = { readonly alias: string; readonly steps: readonly string[] };\n\n/** Marker every chain veto error message carries, followed by `<token>:<nonce>:`. */\nexport const CHAIN_VETO_PREFIX: string = \"__vibe_veto:\";\n\n/** Allowed veto tokens: lower-case words — they are rendered into SQL text. */\nexport const CHAIN_VETO_TOKEN_PATTERN: RegExp = /^[a-z][a-z0-9_]*$/;\n\n/**\n * The veto token a database error message carries for this `nonce`, or\n * `undefined`. Matches the marker anywhere in the text, so a localized server\n * message (`lc_messages`) still yields it: the marker is the invalid VALUE the\n * message quotes. A marker without the caller's nonce is not a veto.\n */\nexport function chainVetoToken(params: { message: string; nonce: string }): string | undefined {\n const { message, nonce } = params;\n if (nonce === \"\") return undefined;\n for (let start = message.indexOf(CHAIN_VETO_PREFIX); start >= 0; start = message.indexOf(CHAIN_VETO_PREFIX, start + 1)) {\n const rest = message.slice(start + CHAIN_VETO_PREFIX.length);\n const match = /^([a-z][a-z0-9_]*):/.exec(rest);\n if (match !== null && rest.startsWith(`${nonce}:`, match[0].length)) return match[1];\n }\n return undefined;\n}\n\n/**\n * ONE statement made of an ordered chain of named steps — reads (a locked\n * probe) and data-modifying statements with RETURNING — ending in a final\n * SELECT over them (round-trip campaign EPIC 4, reused by EPIC F). Renders as\n * `WITH \"a\" AS (…), \"b\" AS (…) SELECT …` on a dialect whose\n * `statementChain` strategy names the form (postgres); every other dialect\n * refuses at render time (`VIBE_UNSUPPORTED_CAPABILITY`) — callers gate on\n * the strategy first and keep their multi-statement path there.\n *\n * PostgreSQL semantics the builder relies on: every step sees ONE snapshot\n * (a step never sees another step's writes — only its RETURNING rows), steps\n * that reference a step run after it, and the statement is atomic: an error in\n * any step undoes every step's effects, trigger writes included.\n */\nexport type ChainStatement = {\n readonly kind: \"chain\";\n readonly steps: readonly ChainStep[];\n readonly result: ChainResult;\n};\n\nexport type SqlStatement = SelectStatement | InsertStatement | UpdateStatement | DeleteStatement |\n RlsEnableStatement | RlsForceStatement | RlsDisableStatement | RlsNoForceStatement | RlsDropPolicyStatement |\n RlsPolicyStatement | RlsContextStatement | RlsRoleStatement | AdvisoryLockStatement | ChainStatement;\n\n/** Readiness statements remain distinct from application queries. */\nexport type RlsReadinessStatement = { readonly kind: \"rlsReadiness\"; readonly query: RlsReadinessQuery; readonly searchPath?: string };\n/** Temporary clone lifecycle surrounding a desired-policy probe. */\nexport type RlsProbeTableStatement = { readonly kind: \"rlsProbeTable\"; readonly table: string; readonly action: \"create\" | \"drop\" };\n/** Migration transaction-local policy search-path scope. */\nexport type RlsPolicyPathStatement = { readonly kind: \"rlsPolicyPath\"; readonly stage: \"save\" | \"empty\" | \"restore\" };\n",
41
+ "import type { NativeEnumArrayParameter } from \"./native-enum-parameter.ts\";\nimport type { JsonListParameter } from \"./json-list-parameter.ts\";\nimport type { SqlFragment } from \"./composable.ts\";\nimport type { RlsReadinessQuery } from \"./dialects/postgres-rls-readiness.ts\";\n/**\n * The SQL AST — the small statement language the runtime and migrate packages\n * build and dialects render.\n *\n * Deliberately minimal at P0 (single-table statements, no joins/subqueries);\n * grows with the runtime in P2/P3. Every shape added here needs a catalog case\n * (tests/catalog/cases.ts) in the same change.\n */\n\nimport type {\n AdvisoryLockMode,\n DateTruncationStorage,\n DateTruncationUnit,\n RlsContextIR,\n RowLockStrength,\n RowLockWaitPolicy,\n ScalarType,\n SchemaIR,\n SqlFragmentSpec,\n} from \"@vibeorm/schema\";\n\n// ─── References ───────────────────────────────────────────────────\n\n/** A column reference, optionally table-qualified. */\nexport type ColRef = {\n readonly table?: string;\n readonly name: string;\n /**\n * Projection-only wire transform. `jsonText` uses the dialect's JSON text\n * projection to preserve SQL NULL versus the JSON document `null` before\n * driver parsing, without converting a postgres `json` column to `jsonb`.\n * `castText` renders a dialect text cast and preserves `alias ?? name`,\n * including timestamp identity before driver Date truncation. PostgreSQL\n * uses `\"col\"::text`; SQLite/MySQL use CAST AS TEXT/CHAR. `encodeBase64`\n * is postgres-only and renders `encode(\"col\", 'base64')`.\n * `encodeArrayBase64` is postgres-only and renders\n * `encode(array_send(\"col\"), 'base64')` — a `bytea[]` column's binary array\n * form (dimensions, NULL elements, raw element bytes) as base64: faithful\n * whatever the session's `bytea_output`, keeping a NULL column (`NULL`), an\n * empty array and NULL elements distinct (5.0 lane V; the lateral subselect's\n * `Bytes[]` form, decoded by the runtime's JSON-transport plan). Other users:\n * the lateral subselect (SQL review B3: raw `to_jsonb` would ship BigInt/Decimal as float64 JSON\n * numbers and Bytes as `\\x` hex text), and every row projection of a\n * `Float[]`/`Json[]` column (bun:sql's array parser refuses float arrays\n * printed with an exponent and json arrays holding integers beyond int32;\n * the runtime parses the array literal text itself). Never set on\n * filter/order refs.\n */\n readonly transform?: \"castText\" | \"encodeBase64\" | \"encodeArrayBase64\" | \"jsonText\";\n /**\n * Comparison/order/aggregate cast, sqlite Decimal only (SQL review B4):\n * Decimal stores as exact TEXT there and text comparison is lexicographic —\n * compare, ORDER BY and aggregate sites render `CAST(\"col\" AS REAL)` (with\n * NUMBER operands) instead. Never set on projections or GROUP BY keys, so\n * storage and read-back stay the exact text.\n */\n readonly castReal?: boolean;\n /**\n * Order/distinct/compare cast, postgres `json` columns only (`Json @db.Json`,\n * release-3.0 D3): `json` has no ordering or equality operator, so ORDER BY,\n * DISTINCT ON and comparison sites render `\"col\"::jsonb` (`\"col\"::jsonb[]`\n * for a `json[]` list column) — the order and distinctness of a jsonb\n * column. Never set on projections, so read-back keeps the stored text.\n */\n readonly castJsonb?: \"jsonb\" | \"jsonb[]\";\n /**\n * Calendar truncation of a timestamp column, for a `groupBy` date key. The\n * reference renders as the start of its period in a named time zone\n * (`date_trunc('day', \"col\", 'Europe/Oslo')`; see `renderDateTruncation`),\n * in the column's own SQL type. Set on the projection, GROUP BY and ORDER BY\n * refs of one key, which then repeat the identical expression text\n * (PostgreSQL matches GROUP BY expressions by structure); a projection keeps\n * `alias ?? name` as its output name. Never set on filter refs. Dialects\n * without the `dateTruncation` capability refuse it when rendering.\n */\n readonly truncate?: DateTruncation;\n /**\n * Projection alias: renders `ref AS \"alias\"`. PROJECTION-ONLY — filter,\n * order and correlation refs never set it (the renderer ignores it outside\n * a projection list). Used by the single-statement M2M join to expose the\n * join table's parent-key column under a reserved name (`__vibe_parent`).\n */\n readonly alias?: string;\n};\n\n/** A {@link ColRef.truncate} request: the calendar unit, the zone that defines the calendar, and the column's storage form. */\nexport type DateTruncation = {\n readonly unit: DateTruncationUnit;\n /** A time-zone name (`\"Europe/Oslo\"`, `\"UTC\"`), rendered as a string literal after a strict character check. */\n readonly timeZone: string;\n readonly storage: DateTruncationStorage;\n};\n\nexport type TableRef = {\n readonly name: string;\n /** Explicit fixed PostgreSQL placement; absence preserves existing SQL. */\n readonly namespace?: string;\n readonly alias?: string;\n};\n\n// ─── Aggregates ───────────────────────────────────────────────────\n\n/** Aggregate functions applied to one column. */\nexport type AggFn = \"count\" | \"avg\" | \"sum\" | \"min\" | \"max\";\n\n/** Reference to an aggregate expression: `COUNT(*)` or `FN(\"col\")`. */\nexport type AggRef =\n | { readonly fn: \"countAll\" }\n | { readonly fn: AggFn; readonly column: ColRef };\n\n/**\n * One aggregate projection: `FN(\"col\") AS \"alias\"`. The alias is part of the\n * catalog contract — the runtime derives result keys from it deterministically\n * (`_count___all`, `_avg__score`), never by parsing the SQL text back.\n */\nexport type AggSelect = {\n readonly agg: AggRef;\n readonly alias: string;\n /** Projection-only result cast; native aggregate comparisons and ordering stay typed. */\n readonly castText?: true;\n};\n\n// ─── JSON filters ─────────────────────────────────────────────────\n\n/**\n * JSON path predicates (Prisma's Json filter surface). `not` is `equals` with\n * `negate` — there is no separate op. Which ops a dialect can express is\n * declared on `SqlDialect.supportedJsonOps` and enforced at render time too.\n */\nexport type JsonFilterOp =\n | \"equals\"\n | \"string_contains\"\n | \"string_starts_with\"\n | \"string_ends_with\"\n | \"array_contains\"\n | \"array_starts_with\"\n | \"array_ends_with\";\n\n// ─── Expressions ──────────────────────────────────────────────────\n\nexport type ComparisonOp = \"eq\" | \"ne\" | \"gt\" | \"gte\" | \"lt\" | \"lte\";\n\n/**\n * The column facts one member of a {@link SqlExpr} `keyList` tuple needs to\n * bind exactly like the equality `\"col\" = $n` would. Postgres binds each\n * member as ONE typed array (`$n::<element type>[]`), so it needs the\n * column's element type: the declared native type without its modifier\n * (`timestamptz`, never `timestamptz(3)` — a typmod cast would round\n * `.1234` onto a stored `.123` that `=` does not match), `bpchar` for\n * `char(n)`, `citext`, the enum's own type. MySQL needs to know a time-of-day\n * member (`SqlDialect.timeOfDayInStrategy`); SQLite needs nothing.\n */\nexport type KeyListMember = {\n /** The column's scalar type; `\"Enum\"` for an enum column. */\n readonly type: ScalarType | \"Enum\";\n /** The declared `@db.*` native type, verbatim (`VarChar(191)`, `Uuid`, `Timestamptz(3)`). */\n readonly nativeType?: string;\n /**\n * A database-stored (native) enum's type: `namespace` qualifies it, absence\n * resolves it through the search path like the statement's table. Absent on\n * a string-stored enum, whose column is text.\n */\n readonly enumType?: { readonly namespace?: string; readonly name: string };\n /** A time-of-day column (`@db.Time(n)` / `@db.Timetz(n)`). */\n readonly timeOfDay?: boolean;\n};\n\nexport type SqlExpr =\n | { readonly kind: \"composed\"; readonly fragment: SqlFragment }\n | { readonly kind: \"cmp\"; readonly op: ComparisonOp; readonly column: ColRef; readonly value: unknown }\n /** Column-to-column comparison — the correlation predicate of EXISTS/lateral subqueries. */\n | { readonly kind: \"cmpCol\"; readonly op: ComparisonOp; readonly left: ColRef; readonly right: ColRef }\n | { readonly kind: \"isNull\"; readonly column: ColRef; readonly negate?: boolean }\n | {\n readonly kind: \"inArray\";\n readonly column: ColRef;\n readonly values: readonly unknown[];\n readonly negate?: boolean;\n /**\n * The column holds a time of day (`@db.Time(n)` / `@db.Timetz(n)`): the\n * dialect renders the membership per `SqlDialect.timeOfDayInStrategy`.\n */\n readonly timeOfDay?: boolean;\n }\n /**\n * ORDERED-TUPLE membership: `(\"a\", \"b\") IN ((?, ?), (?, ?))`. The composite\n * relation predicate — `\"a\" IN (…) AND \"b\" IN (…)` is a Cartesian SUPERSET\n * and is never a substitute. Renders per `SqlDialect.tupleInStrategy`:\n * a native row-value `IN` where the dialect has row constructors, else an OR\n * of COMPLETE conjunctions. Arity 1 is expressed as {@link SqlExpr} `inArray`\n * instead, so single-key relations keep their existing SQL.\n */\n | {\n readonly kind: \"tupleIn\";\n /** Ordered tuple columns; `rows[i][j]` binds to `columns[j]`. */\n readonly columns: readonly ColRef[];\n /** Candidate tuples — every row carries exactly `columns.length` values. */\n readonly rows: readonly (readonly unknown[])[];\n readonly negate?: boolean;\n }\n /**\n * KEY-LIST membership — the public `where: { IN: [{ a, b }, …] }` filter:\n * rows whose ordered tuple of column values equals one of `rows`, with\n * semi-join semantics (a repeated tuple never repeats a result row). Renders\n * per `SqlDialect.keyListStrategy`: postgres binds one typed ARRAY per\n * member, `(\"a\", \"b\") IN (SELECT * FROM unnest($1::int8[], $2::text[]))`,\n * so the text and the planning cost stay constant however long the list is\n * (an OR of 1 000 conjunctions planned in 114 ms on PGlite, 2 ms on\n * postgres 18; the unnest form in 0.1–0.2 ms on both). A `DateTime` member\n * without a declared native type switches postgres to the row-constructor\n * list of untyped parameters (`keyListBindsUntypedRows`: the column may be a\n * zone-less `timestamp`). MySQL renders the row-constructor list, SQLite\n * `IN (VALUES …)`. Each member compares under the column's own type and\n * collation, exactly like `\"col\" = $n`.\n *\n * An empty `rows` renders `1 = 0` (matches nothing, like an empty\n * `inArray`). The runtime emits arity 1 as `inArray` instead, so a\n * one-field key list keeps the scalar `in` SQL.\n */\n | {\n readonly kind: \"keyList\";\n /** Ordered tuple columns (compare references); `rows[i][j]` binds to `columns[j]`. */\n readonly columns: readonly ColRef[];\n /** How each member binds, in column order — see {@link KeyListMember}. */\n readonly members: readonly KeyListMember[];\n /** Encoded candidate tuples, each exactly `columns.length` long; may repeat. */\n readonly rows: readonly (readonly unknown[])[];\n }\n /**\n * ROW-VALUE comparison: `(\"a\", \"b\") > ($1, $2)` — the keyset seek (D-01).\n * SQL compares row values left to right, each pair with that column's own\n * operator, affinity and collation, which is exactly the OR expansion\n * `\"a\" > $1 OR (\"a\" = $2 AND \"b\" > $3)` when no member is NULL — and an\n * index on `(a, b)` bounds it as one range (PostgreSQL `Index Cond: ROW(…) >\n * ROW(…)`, SQLite `SEARCH … (a>?)`). A NULL member makes the comparison\n * UNKNOWN as soon as the scan reaches it, so the runtime emits it only over\n * non-null keys and values. Renders on every dialect (each has row\n * constructors); whether the runtime emits it is\n * `SqlDialect.keysetSeekStrategy`.\n */\n | {\n readonly kind: \"rowCompare\";\n readonly op: \"gt\" | \"gte\" | \"lt\" | \"lte\";\n /** Ordered row members (compare references); `values[i]` binds to `columns[i]`. */\n readonly columns: readonly ColRef[];\n /** Encoded values, exactly `columns.length` of them. */\n readonly values: readonly unknown[];\n }\n /**\n * SUBQUERY membership: `\"id\" IN (SELECT …)`, or the row-value form\n * `(\"a\", \"b\") IN (SELECT …)` for a composite key — the key-first `distinct`\n * page on PostgreSQL (D-04). The subquery projects exactly `columns.length`\n * columns and shares the statement's parameter sequence. MySQL refuses a\n * `LIMIT` directly inside an `IN` subquery (error 1235), so the renderer\n * refuses that pair there with `VIBE_UNSUPPORTED_CAPABILITY`.\n */\n | {\n readonly kind: \"inSelect\";\n /** The tested columns, in the subquery's projection order. */\n readonly columns: readonly ColRef[];\n readonly select: SelectStatement;\n }\n | {\n readonly kind: \"like\";\n readonly column: ColRef;\n /** Pre-built pattern (see like.ts helpers for escaping). */\n readonly pattern: string;\n readonly insensitive?: boolean;\n /**\n * The column carries an explicit case-insensitive collation (@collation\n * `…_ci`, board #36): an insensitive match renders as PLAIN `LIKE` — the\n * collation already folds case, and skipping LOWER() keeps the column\n * indexable. Set by the builder for mysql only.\n */\n readonly ciCollation?: boolean;\n readonly negate?: boolean;\n }\n /**\n * Case-SENSITIVE string match (`mode: \"strict\"`, board #20). `value` is the\n * RAW operand — pattern building happens at render time because escaping\n * differs per strategy (LIKE's `%`/`_`/`\\` vs GLOB's `*`/`?`/`[`). Renders\n * per `SqlDialect.strictMatchStrategy`: plain `=`/`LIKE` on postgres\n * (already byte-sensitive — a deliberate, documented no-op), `=`/`GLOB` on\n * sqlite, `= CAST(? AS BINARY)`/`LIKE CAST(? AS BINARY)` on mysql. The\n * non-native forms defeat plain indexes; docs/dialect-notes.md carries the\n * cost and the functional/`_bin`-index mitigation.\n */\n | {\n readonly kind: \"strictMatch\";\n readonly column: ColRef;\n readonly op: \"equals\" | \"contains\" | \"startsWith\" | \"endsWith\";\n readonly value: string;\n readonly negate?: boolean;\n }\n | { readonly kind: \"and\"; readonly operands: readonly SqlExpr[] }\n | { readonly kind: \"or\"; readonly operands: readonly SqlExpr[] }\n | { readonly kind: \"not\"; readonly operand: SqlExpr }\n /**\n * Correlated subquery test: `[NOT] EXISTS (SELECT …)`. The inner select\n * correlates to the outer scope through table-qualified `cmpCol` predicates;\n * its parameters merge into the statement's single parameter sequence in\n * render order. Relation filters (`some`/`every`/`none`/`is`/`isNot`)\n * compile to this shape.\n */\n | { readonly kind: \"exists\"; readonly select: SelectStatement; readonly negate?: boolean }\n /** Aggregate comparison — the HAVING predicate: `COUNT(\"col\") > $n`. */\n | { readonly kind: \"aggCmp\"; readonly op: ComparisonOp; readonly agg: AggRef; readonly value: unknown }\n /**\n * Scalar-list membership: `$n = ANY(\"col\")` — Prisma's `has`. Postgres only\n * (`capabilities.scalarArrays`); other dialects refuse at render time.\n */\n | { readonly kind: \"arrayHas\"; readonly column: ColRef; readonly value: unknown; readonly negate?: boolean }\n /** Scalar-list superset: `\"col\" @> $n` (one array param) — Prisma's `hasEvery`. Postgres only. */\n | { readonly kind: \"arrayContainsAll\"; readonly column: ColRef; readonly values: readonly unknown[] | string | NativeEnumArrayParameter | JsonListParameter }\n /** Scalar-list overlap: `\"col\" && $n` (one array param) — Prisma's `hasSome`. Postgres only. */\n | { readonly kind: \"arrayOverlaps\"; readonly column: ColRef; readonly values: readonly unknown[] | string | NativeEnumArrayParameter | JsonListParameter }\n /**\n * Scalar-list emptiness via `array_length(\"col\", 1) IS [NOT] NULL` — the v1\n * semantics kept deliberately: `empty: true` matches NULL **and** empty\n * arrays, `empty: false` matches only rows with at least one element.\n */\n | { readonly kind: \"arrayIsEmpty\"; readonly column: ColRef; readonly empty: boolean }\n /**\n * JSON path predicate. The path is always BOUND as a parameter (a `text[]`\n * on postgres, a `$.a.b[0]` path string on sqlite/mysql) — path segments\n * never become SQL text. `value` is the RAW JS operand; each dialect decides\n * its wire form (JSON.stringify for jsonb/json comparisons, LIKE patterns\n * for the string ops). `insensitive` applies to the string ops only.\n */\n | {\n readonly kind: \"jsonFilter\";\n readonly column: ColRef;\n readonly path: readonly (string | number)[];\n readonly op: JsonFilterOp;\n readonly value: unknown;\n readonly insensitive?: boolean;\n readonly negate?: boolean;\n /**\n * The column's postgres type: absent (or `jsonb`) for the default\n * `jsonb`, `json` for `Json @db.Json`. Postgres defines `=`, `<>` and\n * `@>` for jsonb only, so on a `json` column every op casts the\n * EXTRACTED value to jsonb (the string ops then read it as text), which\n * gives a jsonb column's answer. Sqlite and mysql have one JSON type\n * and ignore it.\n */\n readonly storage?: \"jsonb\" | \"json\";\n }\n /**\n * A bound extension fragment: literal text, bound parameters and quoted\n * identifiers in order (extensions.md §3 sql plane — trgm operators, rank\n * and distance terms). Parameters flow through the shared ParamCollector,\n * identifiers through dialect.quoteIdent — never hand-written.\n */\n | { readonly kind: \"fragment\"; readonly fragment: SqlFragmentSpec }\n /** Escape hatch for dialect-reviewed fragments. Text only — no parameters. */\n | { readonly kind: \"raw\"; readonly text: string };\n\n// ─── Projections ──────────────────────────────────────────────────\n\n/**\n * An aggregate projection.\n *\n * `countAll` renders `COUNT(*)`. The alias matters for portability: postgres\n * names the bare column `count`, sqlite and mysql name it `COUNT(*)` — callers\n * that must read the value back always pass an alias. Combined with a\n * non-empty `columns` list (grouped counts, `SELECT \"fk\", COUNT(*) … GROUP\n * BY \"fk\"`), it renders AFTER the columns.\n *\n * `one` renders the constant `1` — the conventional EXISTS projection; it\n * cannot be combined with a column list.\n */\nexport type SelectExpr =\n | { readonly kind: \"countAll\"; readonly alias?: string }\n | { readonly kind: \"one\" };\n\n// ─── SET operations ───────────────────────────────────────────────\n\n/** Arithmetic applied to a column's current value in an UPDATE ... SET. */\nexport type SetOperator = \"increment\" | \"decrement\" | \"multiply\" | \"divide\";\n\n/**\n * An atomic update expression: `\"col\" = \"col\" <op> $n`.\n *\n * Recognised structurally inside `UpdateStatement.set`, so the marker key is\n * deliberately unlikely (`__op`). Three layers keep a user's JSON payload from\n * ever being mistaken for one: the Json codec stringifies JSON values before\n * they reach the AST, the query builder only emits this shape for numeric\n * fields, and {@link isSetOperation} demands only the documented marker keys.\n */\nexport type SetOperation = {\n readonly __op: SetOperator;\n readonly value: number | string | bigint;\n /** Decimal arithmetic needs a REAL operand on SQLite, even for integral text. */\n readonly numericType?: \"Decimal\";\n};\n\nconst SET_OPERATORS: readonly string[] = [\"increment\", \"decrement\", \"multiply\", \"divide\"];\n\n/** Narrow an UPDATE set value to an atomic {@link SetOperation}. */\nexport function isSetOperation(value: unknown): value is SetOperation {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n const keys = Object.keys(value);\n if (!keys.includes(\"__op\") || !keys.includes(\"value\")) return false;\n const candidate = value as { __op: unknown; value: unknown; numericType?: unknown };\n if (keys.length !== 2 && !(keys.length === 3 && keys.includes(\"numericType\") && candidate.numericType === \"Decimal\")) return false;\n return (\n typeof candidate.__op === \"string\" &&\n SET_OPERATORS.includes(candidate.__op) &&\n ((typeof candidate.value === \"number\" && Number.isFinite(candidate.value)) ||\n typeof candidate.value === \"string\" || typeof candidate.value === \"bigint\")\n );\n}\n\n/**\n * A scalar-list update expression (Prisma's `{ push: … }` on list columns):\n * `append` is one element (`\"col\" = array_append(\"col\", $n)`), `concat` an\n * array of elements (`\"col\" = \"col\" || $n`). Postgres only — the query builder\n * gates on `capabilities.scalarArrays` at build time and the renderer refuses\n * too. Same structural-marker discipline as {@link SetOperation}: the key is\n * unlikely, the shape exact, and Json payloads are stringified before they\n * could ever reach an UPDATE set.\n */\nexport type ListSetOperation = {\n readonly __listOp: \"append\" | \"concat\";\n readonly value: unknown;\n};\n\nconst LIST_SET_OPERATORS: readonly string[] = [\"append\", \"concat\"];\n\n/** Narrow an UPDATE set value to a {@link ListSetOperation}. */\nexport function isListSetOperation(value: unknown): value is ListSetOperation {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n const keys = Object.keys(value);\n if (keys.length !== 2 || !keys.includes(\"__listOp\") || !keys.includes(\"value\")) return false;\n const candidate = value as { __listOp: unknown };\n return typeof candidate.__listOp === \"string\" && LIST_SET_OPERATORS.includes(candidate.__listOp);\n}\n\n/**\n * Database-clock marker: renders the DIALECT's `now()` expression — plus an\n * optional offset in seconds (fractional OK) bound as a parameter — instead of binding a\n * client-side timestamp. Flows as a VALUES cell, an UPDATE SET value, or a\n * comparison operand; the runtime's public `dbNow()` sentinel compiles to\n * this marker for DateTime fields (leases, TTLs — anything that must trust\n * the database's clock, never the process's). Same structural-marker\n * discipline as {@link SetOperation}: unlikely key, exact shape.\n */\nexport type DbNowMarker = {\n readonly __dbNow: true;\n readonly offsetSeconds: number;\n};\n\n/** Build a {@link DbNowMarker}; `offsetSeconds` is finite seconds — fractional is legal (lease TTLs arrive as ttlMs / 1000). */\nexport function dbNowMarker(params: { offsetSeconds: number }): DbNowMarker {\n return { __dbNow: true, offsetSeconds: params.offsetSeconds };\n}\n\n/** Narrow a value to a {@link DbNowMarker}. */\nexport function isDbNowMarker(value: unknown): value is DbNowMarker {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return false;\n // A-05: every object cell (each Date of a createMany) is asked; one own-key\n // test rejects them before the key list is built.\n if (!Object.hasOwn(value, \"__dbNow\")) return false;\n const keys = Object.keys(value);\n if (keys.length !== 2 || !keys.includes(\"__dbNow\") || !keys.includes(\"offsetSeconds\")) return false;\n const candidate = value as { __dbNow: unknown; offsetSeconds: unknown };\n return (\n candidate.__dbNow === true &&\n typeof candidate.offsetSeconds === \"number\" &&\n Number.isFinite(candidate.offsetSeconds)\n );\n}\n\n// ─── Ordering ─────────────────────────────────────────────────────\n\n/** ORDER BY a column, with optional NULLS placement (native or emulated per dialect). */\nexport type OrderByColumn = {\n readonly column: ColRef;\n readonly direction: \"asc\" | \"desc\";\n /** NULLS placement; rendered natively or emulated per dialect. */\n readonly nulls?: \"first\" | \"last\";\n};\n\n/** ORDER BY an aggregate expression — grouped selects ordering by `COUNT(\"col\")`. */\nexport type OrderByAggregate = {\n readonly agg: AggRef;\n readonly direction: \"asc\" | \"desc\";\n};\n\n/**\n * ORDER BY a correlated scalar subquery — relation orderBy\n * (`orderBy: { posts: { _count: \"desc\" } }` → `(SELECT COUNT(*) …)` /\n * `orderBy: { author: { email: \"asc\" } }` → `(SELECT \"email\" …)`).\n * Portable: all three dialects order by scalar subqueries. The subquery\n * correlates to the outer scope through table-qualified `cmpCol` predicates,\n * exactly like `exists`; its parameters merge into the statement's single\n * sequence in render order. NULLS placement is deliberately unsupported here\n * (emulating it would render the subquery twice and duplicate its params) —\n * missing relations sort at each engine's native NULL position.\n */\nexport type OrderBySubquery = {\n readonly select: SelectStatement;\n readonly direction: \"asc\" | \"desc\";\n};\n\nexport type OrderTerm = OrderByColumn | OrderByAggregate | OrderBySubquery;\n\n// ─── Statements ───────────────────────────────────────────────────\n\n/**\n * One `LEFT JOIN LATERAL (…) AS alias ON true` clause aggregating a correlated\n * subquery into a single JSON value per outer row — the \"join\" relation-loading\n * strategy (postgres/pglite, and MySQL 8.0.14+ since lane J; gated on\n * `capabilities.lateralJoin` and rendered through `SqlDialect.lateralJson`).\n * MySQL renders positional rows only (`JSON_ARRAY`, `JSON_ARRAYAGG`, `ON\n * true`); its aggregate cannot order, so an ordered list level carries a\n * `select.rowNumber` without partition — rendered as the row's last slot.\n *\n * Renders (agg `jsonArray`):\n * `LEFT JOIN LATERAL (SELECT COALESCE(json_agg(to_json(\"__sub\".*)), '[]'::json)\n * AS \"columnAlias\" FROM (<select>) AS \"__sub\") AS \"alias\" ON true`\n * and (agg `jsonObject`):\n * `LEFT JOIN LATERAL (SELECT to_json(\"__sub\".*) AS \"columnAlias\"\n * FROM (<select>) AS \"__sub\") AS \"alias\" ON true`\n *\n * `to_json` over a subselect (not `json_build_object`) sidesteps postgres's\n * 100-argument function limit on wide models (v1 lesson); `json` rather than\n * `jsonb` because the value is transport only — jsonb's binary build + re-\n * serialization cost 2–3.7× the server time for identical decoded values.\n * The inner select's ORDER BY drives the aggregate's element order. Consumers\n * must run the codec table over the parsed JSON children: `to_json` turns\n * timestamps into strings and loses BigInt-ness (LEARNINGS).\n */\nexport type LateralJoin = {\n /** Join alias (`__lat_0`) — the outer projection selects `alias.columnAlias`. */\n readonly alias: string;\n /** Column the aggregated JSON value is exposed under (`__rel_posts`). */\n readonly columnAlias: string;\n /** jsonArray: many rows; jsonObject: one row or NULL; count: a scalar COUNT(*) lateral. */\n readonly agg: \"jsonArray\" | \"jsonObject\" | \"count\";\n /**\n * Object output is the SQL-layer default. Positional rows follow the exact\n * select.columns order, using explicit output names (never SELECT *).\n * Above JSON_TRANSPORT.chunkSize, a row is an array of fixed-size chunks;\n * the final chunk may be shorter. Scalar/list/Json field values stay in one\n * slot. Consumers must use the SAME projection to decode the payload.\n */\n readonly rowFormat?: \"object\" | \"positional\";\n /** The correlated child select — may reference outer columns via table-qualified refs. */\n readonly select: SelectStatement;\n};\n\n/**\n * One correlated scalar `COUNT(*)` projected into a select list:\n * `(SELECT COUNT(*) FROM … WHERE <correlation>) AS \"alias\"` — the relation\n * `_count` of the round-trip campaign's R-03b, which saves the separate grouped\n * count statement. Portable: postgres, sqlite and mysql all evaluate a\n * correlated scalar subquery once per output row; the runtime wraps a paged\n * root in a derived table first, so the subqueries run only for the page.\n * The select must be ONE ungrouped `COUNT(*)` (`columns: []`, `selectExpr`\n * countAll, no grouping, paging, distinct or lock) — anything else is refused\n * at render. Its parameters join the statement's single sequence in text order\n * (the select list renders before FROM).\n */\nexport type CountSubquery = {\n /** Output column the count is exposed under (`__vibe_count_0`). */\n readonly alias: string;\n /** The correlated count select — references outer columns via table-qualified refs. */\n readonly select: SelectStatement;\n};\n\n/**\n * One `INNER JOIN \"table\" AS alias ON left = right [AND …]` clause — plain\n * equality joins only, portable across all dialects. Added for the\n * single-statement implicit-M2M load (child rows joined to their join-table\n * membership rows); extra join-table columns project through the statement's\n * `columns` list with a table qualifier + `alias`.\n */\nexport type InnerJoin = {\n readonly table: TableRef;\n /** Equality pairs ANDed into the ON clause; never empty. */\n readonly on: readonly { readonly left: ColRef; readonly right: ColRef }[];\n};\n\n// ─── Fix lane Q2 (D-03): derived-table LEFT JOIN ───\n\n/**\n * One `LEFT JOIN (<select>) AS \"alias\" ON \"alias\".\"k\" = \"outer\".\"c\" [AND …]`\n * clause — portable, equality ON pairs only. Built for the to-one relation\n * `orderBy` (`orderBy: { author: { email: \"asc\" } }`): the target's key and\n * sort columns ride a derived table under RESERVED aliases (`__vibe_ok0`,\n * `__vibe_ov0`), so the outer statement's unqualified column names can never\n * become ambiguous, and the outer ORDER BY names `\"alias\".\"__vibe_ov0\"`.\n * Every engine merges such a derived table into a plain join (measured:\n * postgres pulls it up into a hash/nested-loop left join, sqlite flattens it,\n * mysql merges it), so the planner may hash-join instead of evaluating a\n * correlated subquery per candidate row.\n *\n * The builder emits it only for links that match AT MOST ONE target row, so\n * the join keeps the parent row count. The derived select must alias every\n * projected column; its parameters (none today) join the statement's single\n * sequence where the clause renders (after `keyTable`, before\n * `lateralJoins`). A statement with a `rowLock` refuses it: postgres rejects\n * FOR UPDATE on the nullable side of an outer join, and mysql would lock the\n * joined rows too.\n */\nexport type LeftJoin = {\n /** Derived-table alias (`__ord1`). */\n readonly alias: string;\n /** The derived table — every projected column carries an `alias`. */\n readonly select: SelectStatement;\n /** Equality pairs ANDed into the ON clause; never empty. */\n readonly on: readonly { readonly left: ColRef; readonly right: ColRef }[];\n};\n\n/**\n * How one member of a {@link KeyTableJoin} tuple binds inside the derived\n * table. `value` binds the parameter as it is: it stays COERCIBLE, so a text\n * column's OWN collation decides `=` — the equality `col IN (?, …)` uses.\n * `integer` and `decimal` cast the parameter into the column's numeric family:\n * BigInt and Decimal values travel as strings, and a derived-table string\n * compared with a numeric column goes through a double (measured on mysql:\n * `9007199254740993` matched `9007199254740992`).\n *\n * `integer` renders `CAST(? AS SIGNED)`. `decimal` renders\n * `CAST(? AS DECIMAL(65, scale))` with the tested column's own scale: 65 is\n * MySQL's maximum precision, so the cast holds every value a\n * `DECIMAL(p, scale)` column can hold. A fixed `DECIMAL(65,30)` held only 35\n * integer digits and clipped a `Decimal(65, 0)` key onto its maximum, which\n * matched nothing (review finding 1); the column's own precision would clip a\n * wider value onto the column's maximum and pair it with a row it does not\n * equal (measured: `CAST('100000' AS DECIMAL(5,0))` is `99999`). `scale` is\n * 0–30, MySQL's range.\n *\n * `citext` (postgres only) renders `CAST($n AS citext)`: a postgres `citext`\n * key compares case-insensitively, and a bare VALUES parameter would be\n * `text`, whose `=` against a citext column is the case-sensitive text\n * operator. A VALUES cell has no column to infer a type from, so every member\n * of a postgres key table binds typed: `citext`, `text` (`CAST($n AS text)`,\n * a text or varchar column) or `integer` (`CAST($n AS bigint)`, exact against\n * any integer column) — any other member refuses on postgres. `text` is\n * postgres-only; mysql binds text members as `value`.\n */\nexport type KeyTableMember =\n | { readonly kind: \"value\" }\n | { readonly kind: \"integer\" }\n | { readonly kind: \"decimal\"; readonly scale: number }\n /** MySQL-only lossless temporal operands in mixed collation-aware key tuples. */\n | { readonly kind: \"timestamp\" }\n | { readonly kind: \"time\" }\n | { readonly kind: \"citext\" }\n | { readonly kind: \"text\" };\n\n/**\n * The batch's key tuples as a derived table, each tagged with its ORDINAL\n * (row `i` carries `i`), INNER JOINed on the tested columns — mysql:\n * `INNER JOIN (VALUES ROW(?, 0), ROW(?, 1)) AS \\`alias\\` (\\`__vibe_k0\\`, \\`ordinal\\`)\n * ON col = \\`alias\\`.\\`__vibe_k0\\``; postgres only over `citext` members\n * (`(VALUES (CAST($1 AS citext), 0), …)`, release 3.0 nested writes).\n * Member columns are named `__vibe_k<i>` (a reserved prefix, so unqualified\n * child columns never collide with them).\n *\n * Why it exists (EPIC R): a relation load used to stitch children to parents\n * by comparing decoded keys in JavaScript, while mysql's collations equate\n * spellings (`acme` = `Acme` = `ACME`, `cafe` = `Café`, `x ` = `x`) that\n * JavaScript keeps apart — the foreign key and the `IN` filter accepted the\n * child, the stitch dropped it. Joined this way the DATABASE pairs every child\n * row with every batch key it considers equal, and the projected ordinal names\n * the key; the join is also the membership filter.\n */\nexport type KeyTableJoin = {\n /** Derived-table alias (`__vibe_keys`); the ordinal projects as `alias.ordinalAlias`. */\n readonly alias: string;\n /** The statement's columns, compared member by member (`=`), in tuple order. */\n readonly columns: readonly ColRef[];\n /** How each member binds, in tuple order — see {@link KeyTableMember}. */\n readonly members: readonly KeyTableMember[];\n /** Encoded key tuples; never empty, each as long as `columns`. */\n readonly rows: readonly (readonly unknown[])[];\n /** Output name of the ordinal column. */\n readonly ordinalAlias: string;\n};\n\n/**\n * A `ROW_NUMBER() OVER (PARTITION BY … [ORDER BY …]) AS \"alias\"` projection,\n * appended after `columns` — the distinct emulation on dialects without\n * `DISTINCT ON` (sqlite ≥3.25, mysql ≥8.0 both have window functions): the\n * outer statement filters `alias = 1` on the derived table, restoring\n * SQL-side take/skip and bounded transfer (N10).\n */\nexport type RowNumberProjection = {\n readonly partitionBy: readonly ColRef[];\n /** Intra-partition order picking the representative row; may be empty. */\n readonly orderBy: readonly OrderTerm[];\n readonly alias: string;\n};\n\n// ─── Fix lane Q1 (round 3, DB-01): per-key page ──────────────────\n\n/**\n * A PER-KEY PAGE of one child table as a derived-table FROM\n * (`SelectStatement.keyPage`): for every listed key tuple, the child rows\n * whose key columns equal it, ordered by `select.orderBy` and cut by\n * `select.limit`/`select.offset` — each key's OWN page, plus a rank column\n * (`rankAlias`) that orders the rows inside their key. The paged include's\n * `ROW_NUMBER() OVER (PARTITION BY key …)` window returns the same rows but\n * numbers EVERY child of every listed key first; this form reads one page of\n * primary keys per key through an index on (key columns, order columns),\n * then each page row once by its primary key.\n *\n * Rendered per `SqlDialect.keyPageStrategy`:\n * - `lateral` (postgres): `unnest($1::<type>[], …) AS \"__vibe_keys\"\n * (\"__vibe_k0\", …) CROSS JOIN LATERAL (SELECT <identity>, ROW_NUMBER() OVER\n * (PARTITION BY <key> ORDER BY <order>) AS <rank> FROM <table> WHERE <key> =\n * \"__vibe_keys\".\"__vibe_k<i>\" … ORDER BY <order> LIMIT … OFFSET …) AS\n * \"__vibe_ids\" INNER JOIN <table> AS \"__vibe_page\" ON <identity> pairs`.\n * - `inLimit` (sqlite, which has no LATERAL): the key tuples as `(VALUES …)`\n * (columns `column1`, `column2`, …, as SQLite names a VALUES clause's\n * columns) joined to `<table> AS \"__vibe_page\"` ON `(<identity>) IN (SELECT\n * <identity> … WHERE <key> = \"__vibe_keys\".\"column<i>\" … ORDER BY … LIMIT …)`,\n * the rank re-derived over the fetched page (`ROW_NUMBER() OVER (PARTITION\n * BY <key> ORDER BY <order>)`): its values differ from the window's, its\n * order inside a key does not.\n * - `window` (mysql): refused with `VIBE_UNSUPPORTED_CAPABILITY` — measured\n * no gain there; the runtime keeps the window.\n *\n * The caller guarantees what makes the page equal to the window's: the order\n * is total inside a key (the identity columns are among the key and order\n * columns), the key tuples are distinct and compare exactly (no folding\n * collation). Members bind like the key-list filter's (`KeyListMember`).\n */\nexport type KeyPage = {\n /** How each key member binds, in member order (postgres: one typed array each). */\n readonly members: readonly KeyListMember[];\n /** Encoded, distinct key tuples; never empty, each `members.length` long. */\n readonly rows: readonly (readonly unknown[])[];\n /** The child columns each key member equals, in member order (unqualified). */\n readonly keyColumns: readonly ColRef[];\n /** The child's primary-key columns (unqualified) — each page row is read once by them. */\n readonly identity: readonly ColRef[];\n /**\n * ONE key's page: the child `table` (no alias), the projected `columns`\n * (unqualified; transforms and aliases render as usual), an optional extra\n * `where`, the non-empty `orderBy` (plain column terms), `limit`/`offset`.\n * Any other member is refused.\n */\n readonly select: SelectStatement;\n /** Output name of the rank column. */\n readonly rankAlias: string;\n};\n\n/**\n * Statement-count pass EPIC 4 (round-3 ST-07): bound key tuples as the FROM\n * of a select (`SelectStatement.fromKeys`) — a derived table named\n * `table.name` whose columns are `columns`, one row per tuple. The write\n * follow-up puts it where the parent table would be: the find path's laterals\n * correlate to `\"<table.name>\".\"<column>\"` exactly as over the table, but read\n * the RETURNED key values instead of the parent row (a deleted row, or a\n * native-RLS parent whose SELECT policy the per-relation loads never met).\n *\n * Renders where `SqlDialect.keyListStrategy` is `unnest` (postgres) as the\n * typed form of a `VALUES` list — one array per column, typed like the\n * key-list filter's members (`postgresKeyListElementType`), so the text does\n * not depend on the tuple count: `FROM unnest($1::text[], $2::int4[]) AS\n * \"Post\" (\"id\", \"authorId\")`. A `DateTime` member without a declared native\n * type (`keyListBindsUntypedRows`) and every other dialect refuse with\n * `VIBE_UNSUPPORTED_CAPABILITY` — those dialects have no lateral joins either.\n */\nexport type KeyRows = {\n /** Output column names of the derived table, in member order. */\n readonly columns: readonly string[];\n /** How each column binds, in column order — see {@link KeyListMember}. */\n readonly members: readonly KeyListMember[];\n /** Encoded tuples; never empty, each exactly `columns.length` long. */\n readonly rows: readonly (readonly unknown[])[];\n};\n\nexport type SelectStatement = {\n readonly kind: \"select\";\n readonly table: TableRef;\n /** Empty array renders as `SELECT *` (unless `selectExpr` replaces it). */\n readonly columns: readonly ColRef[];\n /**\n * Aggregate projection. Replaces the column list when `columns` is empty;\n * a `countAll` with columns renders after them (grouped counts).\n */\n readonly selectExpr?: SelectExpr;\n /**\n * Aliased aggregate projections (`AVG(\"col\") AS \"_avg__col\"`), rendered\n * after `columns` — the aggregate/groupBy/count-select shapes. Cannot be\n * combined with `selectExpr`.\n */\n readonly aggregates?: readonly AggSelect[];\n /** Correlated `COUNT(*)` subqueries, rendered after `aggregates` — see {@link CountSubquery}. */\n readonly countSubqueries?: readonly CountSubquery[];\n /**\n * `SELECT DISTINCT ON (cols)` — postgres only (`capabilities.distinctOn`;\n * other dialects refuse at render time and the runtime emulates client-side\n * instead). ORDER BY must lead with these columns; the query builder\n * guarantees that arrangement.\n */\n readonly distinctOn?: readonly ColRef[];\n /**\n * Plain `SELECT DISTINCT` over the whole projection — every dialect. The\n * query builder sets it only where it returns exactly the rows its\n * `ROW_NUMBER()` distinct emulation would (sqlite/mysql, value-exact keys,\n * projection equal to the distinct fields); never together with\n * `distinctOn` (the renderer refuses the pair).\n */\n readonly distinct?: true;\n /**\n * Derived-table FROM: renders `FROM (<fromSelect>) AS \"<table.name>\"` —\n * `table.name` is the subquery ALIAS and `table.alias` must be unset. Used\n * by aggregate-over-a-subset shapes (`aggregate({ take, skip, orderBy })`).\n */\n readonly fromSelect?: SelectStatement;\n /** Lateral JSON-aggregation joins — postgres and MySQL 8.0.14+, see {@link LateralJoin}. */\n readonly lateralJoins?: readonly LateralJoin[];\n /** Plain equality INNER JOINs — portable, see {@link InnerJoin}. */\n readonly innerJoins?: readonly InnerJoin[];\n /** Key-table join, rendered after `innerJoins` — mysql only, see {@link KeyTableJoin}. */\n readonly keyTable?: KeyTableJoin;\n /** Fix lane Q2 (D-03): derived-table LEFT JOINs, rendered after `keyTable` — see {@link LeftJoin}. */\n readonly leftJoins?: readonly LeftJoin[];\n /** ROW_NUMBER window projection — see {@link RowNumberProjection}. */\n readonly rowNumber?: RowNumberProjection;\n /**\n * Fix lane Q1 (DB-01): derived-table FROM over a per-key page — renders\n * `FROM (<per-key page>) AS \"<table.name>\"` like `fromSelect` (and never\n * together with it); see {@link KeyPage}.\n */\n readonly keyPage?: KeyPage;\n /**\n * Fix lane Q2 (round 3, DB-07): derived-table FROM over a `UNION ALL` of\n * branch selects — renders `FROM (SELECT * FROM (<branch 0>) AS\n * \"__vibe_u0\" UNION ALL SELECT * FROM (<branch 1>) AS \"__vibe_u1\" …) AS\n * \"<table.name>\"`. Each branch keeps its own ORDER BY and LIMIT: wrapped in\n * its own derived table, a limited branch is valid on all three engines\n * (SQLite refuses ORDER BY/LIMIT on a bare compound member). At least two\n * branches; each a plain `SELECT <columns> FROM <table> [WHERE] [ORDER BY]\n * [LIMIT]` projecting the same output names in the same order; never\n * together with `fromSelect`, `keyPage` or a `table.alias`. Parameters bind\n * branch by branch, in text order.\n */\n readonly fromUnion?: readonly SelectStatement[];\n /**\n * Statement-count pass EPIC 4 (ST-07): derived-table FROM over bound key\n * tuples, named `table.name` with the listed column names — see\n * {@link KeyRows}. Never together with `fromSelect`, `keyPage`, `fromUnion`,\n * a `table.alias` or a `rowLock`.\n */\n readonly fromKeys?: KeyRows;\n readonly where?: SqlExpr;\n readonly groupBy?: readonly ColRef[];\n /** HAVING predicate — grouped selects; may contain `aggCmp` expressions. */\n readonly having?: SqlExpr;\n readonly orderBy?: readonly OrderTerm[];\n readonly limit?: number;\n readonly offset?: number;\n /**\n * Row-locking read (`SELECT … FOR UPDATE SKIP LOCKED`) — see {@link RowLock}.\n * The internal read-before-write overlays (dialects without RETURNING) set\n * the plain `{ strength: \"update\", wait: \"wait\" }` lock. Rendered only where\n * the dialect names the clause (`dialect.rowLockSyntax`); sqlite has none and\n * needs none — its write transactions already exclude each other.\n */\n readonly rowLock?: RowLock;\n};\n\n/**\n * The lock a locking read takes: one strength, one wait policy. Both members\n * are REQUIRED here — defaulting happens once, in the query builder, so the\n * rendered SQL is a function of the AST alone.\n */\nexport type RowLock = {\n readonly strength: RowLockStrength;\n readonly wait: RowLockWaitPolicy;\n};\n\n/**\n * Sentinel VALUES cell: render the `DEFAULT` keyword instead of a placeholder\n * (M4) — a heterogeneous createMany row that omits a field lets the COLUMN\n * default apply (or NULL on a defaultless nullable column), exactly like a\n * single-row insert that omits it. Postgres/mysql only\n * (`dialect.rowDefaultKeyword`); sqlite groups rows instead.\n */\nexport const SQL_DEFAULT_CELL: { readonly __sqlDefault: true } = Object.freeze({ __sqlDefault: true });\n\n/**\n * Sentinel update-arm cell: the column keeps its current value —\n * `` `col` = `table`.`col` `` (V8, the insert-if-missing upsert). Valid only in\n * an {@link OnConflictUpdate} `update` set, where MySQL's `ON DUPLICATE KEY\n * UPDATE` needs at least one assignment: a self-assignment changes nothing on a\n * duplicate and, unlike `INSERT IGNORE`, leaves every other error an error.\n * Refused in a plain UPDATE's SET list.\n */\nexport const SQL_KEEP_CELL: { readonly __sqlKeep: true } = Object.freeze({ __sqlKeep: true });\n\n/** Is this update cell the {@link SQL_KEEP_CELL} sentinel? */\nexport function isSqlKeepCell(value: unknown): boolean {\n return value === SQL_KEEP_CELL;\n}\n\n/** Is this VALUES cell the {@link SQL_DEFAULT_CELL} sentinel? */\nexport function isSqlDefaultCell(value: unknown): boolean {\n return value === SQL_DEFAULT_CELL;\n}\n\n/**\n * VALUES/SET cell carrying a Json column's parameter (the codec's JSON text).\n *\n * Why it exists: OID-typed drivers (bun:sql) resolve each parameter's postgres\n * type and re-serialize the JS value AS that type — a pre-stringified Json\n * param bound straight into a bare jsonb slot arrives DOUBLE-ENCODED (a jsonb\n * string holding the document; live-proven on Bun 1.3.14). The postgres\n * renderer pins the parameter's type instead (`$n::text::jsonb`,\n * `SqlDialect.jsonParamCast`), so every driver sends the text through and the\n * SERVER parses it; text-param drivers (node-postgres, pglite) are unaffected.\n * Sqlite/mysql render the bare placeholder — their Json transport is already\n * plain text. The COLLECTED parameter is the plain text either way: this\n * wrapper never crosses the wire.\n *\n * `storage: \"json\"` marks a postgres `json` column (`Json @db.Json`): the cell\n * renders `$n::text::json`, so the column stores the text as written (key\n * order and spelling kept) instead of jsonb's normalized text (release-3.0\n * D3). Absent = jsonb; dialects without a param cast ignore it.\n */\nexport type JsonParamCell = { readonly __jsonParam: true; readonly text: string; readonly storage?: \"json\" };\n\n/** Wrap a Json column's encoded (stringified) parameter for cast-site rendering. */\nexport function jsonParamCell(params: { text: string; storage?: \"json\" }): JsonParamCell {\n return params.storage === \"json\" ? { __jsonParam: true, text: params.text, storage: \"json\" } : { __jsonParam: true, text: params.text };\n}\n\n/** Is this VALUES/SET cell a {@link JsonParamCell}? */\nexport function isJsonParamCell(value: unknown): value is JsonParamCell {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __jsonParam?: unknown }).__jsonParam === true\n );\n}\n\n/**\n * Reference to the row PROPOSED for insertion, inside an upsert's update arm:\n * `excluded.\"col\"` on postgres/sqlite, `` `new`.`col` `` on mysql's row-alias\n * form (`SqlDialect.excludedRowRef`). It is a COLUMN REFERENCE, not a\n * parameter — it names the value already bound in this statement's VALUES\n * list, which is what lets ONE batched upsert write each conflicting row's own\n * incoming values without binding them a second time.\n */\nexport type ExcludedRef = { readonly __excluded: true; readonly column: string };\n\n/** Reference the incoming row's `column` from inside an upsert update arm. */\nexport function excludedRef(params: { column: string }): ExcludedRef {\n return { __excluded: true, column: params.column };\n}\n\n/** Is this SET cell an {@link ExcludedRef}? */\nexport function isExcludedRef(value: unknown): value is ExcludedRef {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __excluded?: unknown }).__excluded === true\n );\n}\n\n/**\n * One RETURNING column: a bare column name renders `\"col\"`; `castText` renders\n * a dialect text cast (postgres `::text`, sqlite `CAST AS TEXT`) for lossless\n * transport, including timestamps and postgres arrays. `jsonText`\n * applies the dialect's JSON text projection, as {@link ColRef.transform} does\n * for SELECT. Dialects without RETURNING still omit the clause and flag it.\n */\nexport type ReturningColumn =\n | string\n | { readonly name: string; readonly castText: true }\n | { readonly name: string; readonly transform: \"jsonText\" };\n\n/** The column name a {@link ReturningColumn} exposes in the result row. */\nexport function returningColumnName(column: ReturningColumn): string {\n return typeof column === \"string\" ? column : column.name;\n}\n\nexport type InsertStatement = {\n readonly kind: \"insert\";\n readonly table: TableRef;\n readonly columns: readonly string[];\n /** Row values aligned to `columns` — deterministic parameter order. */\n readonly rows: readonly (readonly unknown[])[];\n /** Upsert clause: ON CONFLICT (pg/sqlite) or ON DUPLICATE KEY (mysql). */\n readonly onConflict?: OnConflictClause;\n /** Rendered as RETURNING where the dialect supports it, else omitted+flagged. */\n readonly returning?: readonly ReturningColumn[];\n /**\n * Bind the rows as ONE typed array per column instead of one parameter per\n * value (`SqlDialect.bulkInsertForm` `\"unnest\"`, postgres): `INSERT INTO t\n * (\"a\", \"b\") SELECT \"c1\", \"c2\" FROM unnest($1::text[], $2::int4[]) WITH\n * ORDINALITY AS \"__vibe_rows\" (\"c1\", \"c2\", \"ord\") ORDER BY \"ord\"`. The text\n * is the same for 2 rows and for 3 000, and the statement binds one parameter\n * per column. `ORDER BY \"ord\"` keeps input order (sequence values, the\n * `ON CONFLICT DO NOTHING` winner).\n *\n * One entry per column, in `columns` order: the column's DECLARED type facts\n * (see {@link KeyListMember}; a `Json` entry names its storage through\n * `nativeType`). Each array binds the BASE type (`varchar`, never\n * `varchar(191)` — an explicit modifier cast truncates silently), so the\n * INSERT's own assignment applies the column's length and precision exactly\n * as it does for a VALUES parameter. `rows` stays row-major: the renderer\n * transposes it. Every cell is a plain value, SQL NULL or a\n * {@link JsonParamCell} — never `DEFAULT` or the database clock (the query\n * builder keeps VALUES for those; the renderer refuses them).\n */\n readonly unnest?: readonly KeyListMember[];\n};\n\n/** Conflicting rows are updated with these column values. */\nexport type OnConflictUpdate = {\n /** Conflict target columns (ignored by the mysql form). */\n readonly columns: readonly string[];\n /**\n * Named-constraint target: `ON CONFLICT ON CONSTRAINT \"name\" DO UPDATE`.\n * Postgres only; replaces the column-list target when present.\n */\n readonly constraint?: string;\n /**\n * Partial-index arbiter predicate, RAW SQL: `ON CONFLICT (cols) WHERE pred\n * DO UPDATE …` (postgres/sqlite; requires `columns`). Raw for the same\n * reason {@link OnConflictDoNothing.conflictWhere} is — both engines match\n * the clause against the index's OWN stored predicate structurally, so a\n * bound parameter could never match and the text mirrors the schema\n * declaration byte-for-byte. Mysql's ODKU names no target and refuses it.\n */\n readonly conflictWhere?: string;\n readonly update: Readonly<Record<string, unknown>>;\n /**\n * Guard on the update arm, BOUND parameters: `ON CONFLICT (…) DO UPDATE SET\n * … WHERE <guard>` — the conflicting row is updated (and returned) only when\n * the guard admits it; otherwise the statement writes and returns nothing.\n * Postgres has both the target row and `excluded` in scope there, so every\n * column ref must carry `table` (the target table's name), exactly as the\n * SET self-references do. Needs the `conflictUpdateWhere` capability:\n * mysql's ODKU has no WHERE and refuses it (`VIBE_UNSUPPORTED_CAPABILITY`).\n */\n readonly updateWhere?: SqlExpr;\n /**\n * MySQL only (`upsertForm: \"onDuplicateKey\"`): append\n * `` `col` = LAST_INSERT_ID(`col`) `` to the update list so the UPDATE arm\n * records the addressed row's key — without it `LAST_INSERT_ID()` is stale\n * on the update arm and the read-back can resolve a wrong, unrelated row\n * (SQL review B2, live-proven on 8.4). Only meaningful for integer keys.\n */\n readonly lastInsertIdColumn?: string;\n};\n\n/**\n * Conflicting rows are skipped (`createMany({ skipDuplicates: true })`).\n * An empty/absent target means \"any conflict\" — the mysql form\n * (`ON DUPLICATE KEY UPDATE k = t.k`, dialect `doNothingForm:\n * \"duplicateKeyKeep\"`) can only express that, so it ignores a bare `columns`\n * target (documented degradation) and REFUSES the refined targets below.\n */\nexport type OnConflictDoNothing = {\n /**\n * MySQL form only (`duplicateKeyKeep`): the column the duplicate arm assigns\n * to itself (`` `k` = `t`.`k` ``, a no-op). Absent = the first inserted\n * column; an all-default row (no column) must name one.\n */\n readonly keepColumn?: string;\n /**\n * MySQL form only, single-row statements: a decimal literal S (digits only).\n * The keep assignment becomes `` `k` = IF(LAST_INSERT_ID(S), `t`.`k`, `t`.`k`) ``,\n * so a skipped duplicate reports S as the statement's insert id (an inserted\n * row reports its own id, or 0) — the exact skipped verdict that the\n * affected count cannot give with CLIENT_FOUND_ROWS (an unchanged duplicate\n * counts 1, like an insert). The builder picks S unequal to the row's\n * explicit AUTO_INCREMENT value.\n */\n readonly duplicateFlag?: string;\n readonly columns?: readonly string[];\n /**\n * Partial-index target predicate, RAW SQL: `ON CONFLICT (cols) WHERE pred\n * DO NOTHING` (postgres/sqlite; requires `columns`). Raw — and rendered\n * verbatim — because BOTH engines match the clause against the index's OWN\n * stored predicate structurally: a bound parameter could never match, so\n * the text mirrors the schema declaration's `where:` string byte-for-byte.\n */\n readonly conflictWhere?: string;\n /** Named-constraint target (`ON CONSTRAINT \"name\"`) — postgres only. */\n readonly constraint?: string;\n readonly doNothing: true;\n};\n\nexport type OnConflictClause = OnConflictUpdate | OnConflictDoNothing;\n\nexport type UpdateStatement = {\n readonly kind: \"update\";\n readonly table: TableRef;\n /**\n * Column → parameter value, or an atomic {@link SetOperation}. As a\n * {@link ChainStep} only (statement-maxx lane C3), a value may be a\n * {@link StepColumnRef} to an EARLIER step: `\"col\" = (SELECT \"c\" FROM\n * \"step\")` — the step must return at most one row (an owner resolved by a\n * unique where, or an owner INSERT of one row).\n */\n readonly set: Readonly<Record<string, unknown>>;\n readonly where?: SqlExpr;\n readonly returning?: readonly ReturningColumn[];\n};\n\nexport type DeleteStatement = {\n readonly kind: \"delete\";\n readonly table: TableRef;\n readonly where?: SqlExpr;\n readonly returning?: readonly ReturningColumn[];\n};\n\n/** Native RLS DDL, kept distinct from ordinary row-query expressions. */\nexport type RlsEnableStatement = { readonly kind: \"rlsEnable\"; readonly table: string };\nexport type RlsForceStatement = { readonly kind: \"rlsForce\"; readonly table: string };\n/** Disable native row policy enforcement on a physical table. */\nexport type RlsDisableStatement = { readonly kind: \"rlsDisable\"; readonly table: string };\n/** Remove forced owner enforcement on a physical table. */\nexport type RlsNoForceStatement = { readonly kind: \"rlsNoForce\"; readonly table: string };\n/** Drop the managed policy by default, or the supplied policy name. */\nexport type RlsDropPolicyStatement = { readonly kind: \"rlsDropPolicy\"; readonly table: string; readonly policyName?: string };\nexport type RlsPolicyStatement = {\n readonly kind: \"rlsPolicy\";\n readonly schema: SchemaIR;\n readonly model: string;\n /** Probe policies use a distinct identity without changing the predicate. */\n readonly policyName?: string;\n /** Only the probe target may be temporary; parent relations always remain public. */\n readonly targetSchema?: \"public\" | \"pg_temp\";\n};\n\n/** Values are validated/serialized by runtime; null is the absent setting sentinel. */\nexport type RlsContextStatement = {\n readonly kind: \"rlsContext\";\n readonly context: RlsContextIR;\n readonly values: Readonly<Record<string, string | null>>;\n /** PGlite: bind this trusted runtime role first, in the same statement. */\n readonly role?: string;\n /** Switch the transaction to READ ONLY in the same statement, after the claims. */\n readonly readOnly?: boolean;\n /** Report the backend as `\"backendPid\"` / `\"backendStart\"` text columns. */\n readonly backend?: boolean;\n};\n\n/** Trusted pre-existing PGlite execution role; never a request-supplied principal. */\nexport type RlsRoleStatement = { readonly kind: \"rlsRole\"; readonly role: string };\n\n// ─── Advisory locks ───────────────────────────────────────────────\n\n/**\n * An advisory lock's key: a lock space the APPLICATION defines, so a resource\n * with no row of its own can still be locked.\n *\n * Two forms, exactly as PostgreSQL offers them, and they are DIFFERENT lock\n * spaces — holding `{ classId: 11, objectId: 22 }` does not block the single\n * key `11 * 2^32 + 22` (probe-verified on PostgreSQL 18.6). Pick one form per\n * resource family and stay in it.\n */\nexport type AdvisoryLockKey =\n | { readonly key: bigint }\n | { readonly classId: number; readonly objectId: number };\n\n/**\n * Take a TRANSACTION-scoped advisory lock. Released by commit and by rollback\n * (including `ROLLBACK TO SAVEPOINT` when it was taken after the savepoint —\n * probe-verified), never by an explicit unlock call, so no leak can outlive the\n * transaction on a pooled connection.\n *\n * `wait: \"nowait\"` renders the `pg_try_advisory_xact_lock*` family, whose single\n * boolean column says whether the lock was taken; `\"wait\"` renders the blocking\n * family, which returns void.\n */\nexport type AdvisoryLockStatement = {\n readonly kind: \"advisoryLock\";\n readonly mode: AdvisoryLockMode;\n readonly wait: \"wait\" | \"nowait\";\n readonly key: AdvisoryLockKey;\n};\n\n/** The column an advisory try-lock projects its verdict into. */\nexport const ADVISORY_LOCK_RESULT_COLUMN: string = \"acquired\";\n\n// ─── Statement chains ────────────────────────────────────────────────\n\n/**\n * A cell of an {@link InsertSelectStatement} that reads a column of an EARLIER\n * chain step: `\"step\".\"column\"`. A column reference, not a parameter — the\n * value comes from the step's rows inside the same statement (a child row\n * taking its parent's key from the parent step, round-trip campaign EPIC F).\n * The step must be named in the insert's `from` list.\n */\nexport type StepColumnRef = { readonly __stepColumn: true; readonly step: string; readonly column: string };\n\n/** Reference `column` of the earlier chain step `step` from an INSERT … SELECT cell. */\nexport function stepColumnRef(params: { step: string; column: string }): StepColumnRef {\n return { __stepColumn: true, step: params.step, column: params.column };\n}\n\n/** Is this INSERT … SELECT cell a {@link StepColumnRef}? */\nexport function isStepColumnRef(value: unknown): value is StepColumnRef {\n return (\n typeof value === \"object\" &&\n value !== null &&\n (value as { __stepColumn?: unknown }).__stepColumn === true\n );\n}\n\n/**\n * `INSERT INTO t (cols) SELECT <cells> [FROM \"step\", …] [WHERE <expr>]\n * [RETURNING …]` — an INSERT whose ONE row is a SELECT list instead of a\n * VALUES row, so a WHERE can veto the write inside the statement and cells can\n * read earlier steps. Valid ONLY as a {@link ChainStep} statement.\n *\n * Cells take the same forms as a VALUES cell — a codec-encoded value, a\n * {@link JsonParamCell}, a {@link DbNowMarker} — plus {@link StepColumnRef}.\n * The {@link SQL_DEFAULT_CELL} is refused: `DEFAULT` is not allowed in a SELECT\n * list; an omitted column takes its default by being absent from `columns`.\n *\n * Parameter typing (O-03, probed on PostgreSQL): a bare parameter in this\n * one-row SELECT list takes the TARGET column's type, exactly as in VALUES.\n */\nexport type InsertSelectStatement = {\n readonly kind: \"insertSelect\";\n readonly table: TableRef;\n readonly columns: readonly string[];\n /** One cell per column, aligned to `columns` — deterministic parameter order. */\n readonly cells: readonly unknown[];\n /** Earlier chain steps the SELECT reads FROM, in order (absent: a one-row SELECT without FROM). */\n readonly from?: readonly string[];\n /**\n * Several source rows (round-trip campaign EPIC F): the SELECT reads them\n * from a derived table `alias`, joined after the `from` steps, and the\n * `cells` read its columns through `stepColumnRef({ step: alias, column })`.\n * See {@link ChainRowSource} for how the rows are typed.\n */\n readonly source?: ChainRowSource;\n readonly where?: SqlExpr;\n /**\n * `ON CONFLICT (<columns>) DO NOTHING` (statement-maxx lane C2): a row whose\n * conflict target already exists is skipped and not returned — the implicit\n * many-to-many join INSERT, where re-connecting an existing pair is a no-op.\n * Postgres form only (the chain renders nowhere else); at least one column.\n */\n readonly conflictDoNothing?: { readonly columns: readonly string[] };\n readonly returning?: readonly ReturningColumn[];\n};\n\n/**\n * Rows an {@link InsertSelectStatement} inserts, as ONE derived table:\n * `(SELECT <cols> FROM (VALUES (<typed NULL row>), ($1, $2), …) AS \"alias\"\n * (<cols>) OFFSET 1) AS \"alias\"`.\n *\n * Why the typed NULL row (review O-03): a bare parameter outside the INSERT's\n * own VALUES has no type, and PostgreSQL resolves an all-parameter column of a\n * VALUES list or UNION in FROM as `text` (\"column is of type integer but\n * expression is of type text\"). The first row is one `(SELECT \"col\" FROM\n * <typedBy> WHERE FALSE)` per column — a NULL of the TARGET column's exact\n * type (enums, `numeric(p,s)`, `varchar(n)`, domains and arrays included) —\n * so every parameter below takes that type, with no cast map anywhere;\n * `OFFSET 1` drops the row. (A `UNION ALL` of one-row SELECTs types the same\n * way but costs ~10× the planning time at 1000 rows — EPIC F shape gate.)\n *\n * Cells take the VALUES forms: a codec-encoded value, a {@link JsonParamCell}\n * or a {@link DbNowMarker}; the DEFAULT cell is refused (a homogeneous row set\n * omits the column instead). A cell carrying its OWN type (the Json cast, the\n * clock) must agree with the column's type under VALUES' common-type rules,\n * which are stricter than INSERT's assignment casts — the builder keeps such\n * columns out (EPIC F eligibility). Rows are read in list order, which is the\n * order the INSERT consumes them.\n */\nexport type ChainRowSource = {\n readonly alias: string;\n /** The table whose columns type the rows — normally the INSERT's own table. */\n readonly typedBy: TableRef;\n readonly columns: readonly string[];\n /** At least one row, each aligned to `columns`. */\n readonly rows: readonly (readonly unknown[])[];\n};\n\n/** What one chain step may be: a read, or a data-modifying statement with RETURNING. */\nexport type ChainStepStatement =\n | SelectStatement\n | InsertStatement\n | InsertSelectStatement\n | UpdateStatement\n | DeleteStatement;\n\n/**\n * One named step: rendered `\"name\" AS (<statement>)`. Later steps and the\n * result read it as a table (`FROM \"name\"`, `EXISTS (SELECT 1 FROM \"name\" …)`,\n * a {@link StepColumnRef}). A data-modifying step contributes the rows its\n * RETURNING list names.\n */\nexport type ChainStep = {\n readonly name: string;\n readonly statement: ChainStepStatement;\n};\n\n/**\n * The chain's final SELECT: the rows of `rowsFrom` (in that order, `UNION\n * ALL`), each projecting `columns`.\n *\n * `verdict` adds one column `alias` = `expr` to every row, AND guarantees a\n * row: when the `rowsFrom` steps return nothing, the result is exactly ONE\n * verdict row whose `columns` are all NULL. A caller recognizes it by NULL in\n * a column the steps never return as NULL (a primary key). Accounting\n * consequence: such a statement returns one row per written row OR one\n * verdict row — a caller that counts returned rows as row changes must undo a\n * verdict-row outcome (the upsert fold always rolls it back).\n */\nexport type ChainResult = {\n readonly rowsFrom: readonly string[];\n readonly columns: readonly string[];\n readonly verdict?: { readonly alias: string; readonly expr: SqlExpr };\n /**\n * In-statement vetoes (round-trip campaign EPIC F), checked in order: when\n * `step` returned no row (fewer than `minRows`, EPIC W), the STATEMENT FAILS — so the database undoes every\n * effect of every step, trigger writes included — with an error whose\n * message carries `__vibe_veto:<token>:<nonce>:` ({@link CHAIN_VETO_PREFIX},\n * {@link chainVetoToken}). Requires `tally`: the veto is the tally column's\n * guard, so it is evaluated exactly once, on the one guaranteed result row.\n */\n readonly veto?: readonly ChainVeto[];\n /**\n * One column `alias` on every result row: the number of rows the listed\n * data-modifying steps returned (their RETURNING rows = their direct\n * effects). Guarantees one row like `verdict`. Row-change accounting reads\n * it instead of counting result rows (effect `writeTally`).\n */\n readonly tally?: ChainTally;\n};\n\n/**\n * Fail the statement when `step` returned no row; `token` names the veto in the\n * error. `nonce` is bound as a PARAMETER into the marker (never SQL text): a\n * per-call random value the caller requires back in the error, so a user value\n * that merely looks like a marker is never read as a veto.\n *\n * `minRows` (EPIC W) makes the veto count-sensitive: the statement fails when\n * `step` returned FEWER rows than that (a multi-row INSERT a trigger shortened).\n * Omitted or 1 = \"no row\". A positive safe integer, rendered as SQL text.\n */\nexport type ChainVeto = { readonly step: string; readonly token: string; readonly nonce: string; readonly minRows?: number };\n\n/** Count the RETURNING rows of `steps` into the result column `alias`. */\nexport type ChainTally = { readonly alias: string; readonly steps: readonly string[] };\n\n/** Marker every chain veto error message carries, followed by `<token>:<nonce>:`. */\nexport const CHAIN_VETO_PREFIX: string = \"__vibe_veto:\";\n\n/** Allowed veto tokens: lower-case words — they are rendered into SQL text. */\nexport const CHAIN_VETO_TOKEN_PATTERN: RegExp = /^[a-z][a-z0-9_]*$/;\n\n/**\n * The veto token a database error message carries for this `nonce`, or\n * `undefined`. Matches the marker anywhere in the text, so a localized server\n * message (`lc_messages`) still yields it: the marker is the invalid VALUE the\n * message quotes. A marker without the caller's nonce is not a veto.\n */\nexport function chainVetoToken(params: { message: string; nonce: string }): string | undefined {\n const { message, nonce } = params;\n if (nonce === \"\") return undefined;\n for (let start = message.indexOf(CHAIN_VETO_PREFIX); start >= 0; start = message.indexOf(CHAIN_VETO_PREFIX, start + 1)) {\n const rest = message.slice(start + CHAIN_VETO_PREFIX.length);\n const match = /^([a-z][a-z0-9_]*):/.exec(rest);\n if (match !== null && rest.startsWith(`${nonce}:`, match[0].length)) return match[1];\n }\n return undefined;\n}\n\n/**\n * ONE statement made of an ordered chain of named steps — reads (a locked\n * probe) and data-modifying statements with RETURNING — ending in a final\n * SELECT over them (round-trip campaign EPIC 4, reused by EPIC F). Renders as\n * `WITH \"a\" AS (…), \"b\" AS (…) SELECT …` on a dialect whose\n * `statementChain` strategy names the form (postgres); every other dialect\n * refuses at render time (`VIBE_UNSUPPORTED_CAPABILITY`) — callers gate on\n * the strategy first and keep their multi-statement path there.\n *\n * PostgreSQL semantics the builder relies on: every step sees ONE snapshot\n * (a step never sees another step's writes — only its RETURNING rows), steps\n * that reference a step run after it, and the statement is atomic: an error in\n * any step undoes every step's effects, trigger writes included.\n */\nexport type ChainStatement = {\n readonly kind: \"chain\";\n readonly steps: readonly ChainStep[];\n readonly result: ChainResult;\n};\n\nexport type SqlStatement = SelectStatement | InsertStatement | UpdateStatement | DeleteStatement |\n RlsEnableStatement | RlsForceStatement | RlsDisableStatement | RlsNoForceStatement | RlsDropPolicyStatement |\n RlsPolicyStatement | RlsContextStatement | RlsRoleStatement | AdvisoryLockStatement | ChainStatement;\n\n/** Readiness statements remain distinct from application queries. */\nexport type RlsReadinessStatement = { readonly kind: \"rlsReadiness\"; readonly query: RlsReadinessQuery; readonly searchPath?: string };\n/** Temporary clone lifecycle surrounding a desired-policy probe. */\nexport type RlsProbeTableStatement = { readonly kind: \"rlsProbeTable\"; readonly table: string; readonly action: \"create\" | \"drop\" };\n/** Migration transaction-local policy search-path scope. */\nexport type RlsPolicyPathStatement = { readonly kind: \"rlsPolicyPath\"; readonly stage: \"save\" | \"empty\" | \"restore\" };\n",
42
42
  "/**\n * Lock SQL: the row-locking clause appended to a SELECT, and the\n * transaction-scoped advisory-lock statement.\n *\n * Both are pure text decisions, so both live here rather than in the runtime —\n * and both REFUSE rather than degrade. A dialect that cannot express a strength\n * or a wait policy has no text for it (`SqlDialect.rowLockSyntax`), and the\n * refusal is a `VIBE_UNSUPPORTED_CAPABILITY`, never a weaker clause: silently\n * turning `skipLocked` into a blocking read hands two workers the same job.\n */\n\nimport { internalError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { AdvisoryLockMode, RowLockStrength, RowLockWaitPolicy } from \"@vibeorm/schema\";\nimport type { AdvisoryLockKey, AdvisoryLockStatement, RowLock } from \"./ast.ts\";\nimport { ADVISORY_LOCK_RESULT_COLUMN } from \"./ast.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport type { ParamCollector } from \"./params.ts\";\nimport type { RenderedQuery } from \"./render.ts\";\n\n// ─── Row locks ────────────────────────────────────────────────────\n\n/**\n * How each strength and wait policy READS in a refusal message. Typed as a\n * total record, so adding a member to either union fails to compile until this\n * table names it — an error message can never silently describe the wrong lock.\n */\nconst ROW_LOCK_PROSE: {\n readonly strengths: Readonly<Record<RowLockStrength, string>>;\n readonly wait: Readonly<Record<RowLockWaitPolicy, string>>;\n} = Object.freeze({\n strengths: Object.freeze({\n update: \"FOR UPDATE\",\n noKeyUpdate: \"FOR NO KEY UPDATE\",\n share: \"FOR SHARE\",\n keyShare: \"FOR KEY SHARE\",\n }),\n wait: Object.freeze({ wait: \"\", nowait: \" NOWAIT\", skipLocked: \" SKIP LOCKED\" }),\n});\n\n/** How a lock request reads in a refusal message (`FOR UPDATE SKIP LOCKED`). */\nexport function describeRowLock(params: { lock: RowLock }): string {\n const { strength, wait } = params.lock;\n return `${ROW_LOCK_PROSE.strengths[strength]}${ROW_LOCK_PROSE.wait[wait]}`;\n}\n\n/**\n * The clause for one row lock, or `null` when this dialect has NO locking-read\n * clause at all and the request is the historical `FOR UPDATE` no-op.\n *\n * sqlite is that case: it has no clause, and its write transactions are\n * mutually exclusive, so `lock: \"update\"` there is a documented no-op kept for\n * compatibility. Anything else on such a dialect — a different strength, or a\n * wait policy that changes behaviour — is refused by the caller BEFORE this\n * point (the query builder), and refused again here as a backstop.\n */\nexport function renderRowLockClause(params: { dialect: SqlDialect; lock: RowLock }): string | null {\n const { dialect, lock } = params;\n const syntax = dialect.rowLockSyntax;\n if (syntax === null) {\n if (lock.strength === \"update\" && lock.wait === \"wait\") return null;\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `a ${describeRowLock({ lock })} locking read`,\n hint: `${dialect.name} has no locking-read clause at all`,\n });\n }\n const strengthText = syntax.strengths[lock.strength];\n if (strengthText === undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `the ${describeRowLock({ lock: { ...lock, wait: \"wait\" } })} row-lock strength`,\n hint: `${dialect.name} can express: ${Object.keys(syntax.strengths).join(\", \")}`,\n });\n }\n const waitText = syntax.wait[lock.wait];\n if (waitText === undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `the \"${lock.wait}\" lock wait policy`,\n hint: `${dialect.name} can express: ${Object.keys(syntax.wait).join(\", \")}`,\n });\n }\n return `${strengthText}${waitText}`;\n}\n\n// ─── Advisory locks ───────────────────────────────────────────────\n\n/** Largest/smallest value each advisory key part may carry, per PostgreSQL's types. */\nexport const ADVISORY_KEY_BOUNDS: {\n readonly single: { readonly min: bigint; readonly max: bigint };\n readonly pair: { readonly min: number; readonly max: number };\n} = Object.freeze({\n single: Object.freeze({ min: -(2n ** 63n), max: 2n ** 63n - 1n }),\n pair: Object.freeze({ min: -(2 ** 31), max: 2 ** 31 - 1 }),\n});\n\n/** Is this key the single 64-bit form? (The alternative is the two 32-bit form.) */\nfunction isSingleKey(key: AdvisoryLockKey): key is { readonly key: bigint } {\n return \"key\" in key;\n}\n\n/**\n * `SELECT pg_advisory_xact_lock($1::bigint)` and friends.\n *\n * The key binds as TEXT with an explicit cast: PostgreSQL overloads these\n * functions on `(bigint)` and `(int4, int4)`, and an OID-typed driver resolves\n * a bound parameter's type itself — the trap `jsonParamCast` already exists for.\n * Casting in the SQL makes every driver send the same bytes.\n */\nexport function renderAdvisoryLock(params: {\n dialect: SqlDialect;\n statement: AdvisoryLockStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n const functions = dialect.advisoryLockFunctions;\n if (functions === null) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"advisory locks\",\n hint:\n dialect.name === \"mysql\"\n ? \"mysql's GET_LOCK is SESSION-scoped — it survives a rollback, so it cannot be released with the transaction\"\n : `${dialect.name} has no advisory-lock functions`,\n });\n }\n const mode: AdvisoryLockMode = statement.mode;\n const fn = (mode === \"exclusive\" ? functions.exclusive : functions.shared)[statement.wait];\n const key = statement.key;\n const args = isSingleKey(key)\n ? `${collector.add(key.key.toString())}${functions.keyCast.single}`\n : `${collector.add(String(assertInt32({ value: key.classId, part: \"classId\" })))}${functions.keyCast.pair}, ` +\n `${collector.add(String(assertInt32({ value: key.objectId, part: \"objectId\" })))}${functions.keyCast.pair}`;\n // The try-lock's boolean IS the result, so it is projected under a stable\n // name; the blocking form returns void and needs no alias.\n const projection =\n statement.wait === \"nowait\"\n ? ` AS ${dialect.quoteIdent({ name: ADVISORY_LOCK_RESULT_COLUMN })}`\n : \"\";\n return {\n text: `SELECT ${fn}(${args})${projection}`,\n values: collector.values,\n returning: \"none\",\n };\n}\n\n/** The AST is built by VibeORM code, so an out-of-range part is our bug. */\nfunction assertInt32(params: { value: number; part: string }): number {\n const { value, part } = params;\n if (\n !Number.isInteger(value) ||\n value < ADVISORY_KEY_BOUNDS.pair.min ||\n value > ADVISORY_KEY_BOUNDS.pair.max\n ) {\n throw internalError({\n message: `advisory lock ${part} must be a 32-bit integer, got ${String(value)}`,\n meta: { part, value },\n });\n }\n return value;\n}\n",
43
43
  "import type { ColRef } from \"./ast.ts\";\n\n/** PostgreSQL FUNC_MAX_ARGS: each json_build_array call accepts at most 100 values. */\nexport const JSON_TRANSPORT: Readonly<{ chunkSize: number }> = Object.freeze({ chunkSize: 100 });\n\n/** The name visible through a subselect, matching the projection renderer's alias rules. */\nexport function projectionOutputName(params: { column: ColRef }): string {\n const { column } = params;\n return column.alias ?? column.name;\n}\n",
44
44
  "/**\n * PostgreSQL dialect. Also serves PGlite — the differences are adapter-level\n * (single connection, bundled extension set), not SQL-text-level.\n */\n\nimport type { SqlDialect } from \"../dialect.ts\";\nimport { POSTGRES_CAPABILITIES } from \"../capabilities.ts\";\nimport { assertNoNul } from \"../identifiers.ts\";\n\nexport const postgresDialect: SqlDialect = {\n name: \"postgres\",\n capabilities: POSTGRES_CAPABILITIES,\n\n inArrayStrategy: \"any\",\n tupleInStrategy: \"rowValue\",\n keyListStrategy: \"unnest\",\n keysetSeekStrategy: \"rowValue\",\n keyPageStrategy: \"lateral\",\n lateralJson: { rowArray: \"json_build_array\", arrayAgg: \"json_agg\", emptyArray: \"'[]'::json\", order: \"inAggregate\", timeOfDayAsText: false, requiresUtcDateTimeWire: false },\n relationStrategyDefault: \"join\",\n relationFilterStrategy: \"exists\",\n // Fix lane Q2 (DB-02/DB-07): the key page gains only as an index-only scan;\n // a btree stores NULLs last on ASC, so `desc nulls last` / `asc nulls first` sort the table.\n deferredJoinPage: { minSkip: 1000, requiresCoveringIndex: true },\n nativeNullsOrder: \"high\",\n nullsUnionPage: true,\n timeOfDayInStrategy: \"in\",\n upsertForm: \"onConflict\",\n // Measured on postgres 16.14 (notes-B.md): a batch proposing one conflict key\n // twice raises SQLSTATE 21000 (\"ON CONFLICT DO UPDATE command cannot affect\n // row a second time\") — including when the two keys are only equal under a\n // nondeterministic ICU collation, a char(n) trailing-space pad, `numeric`\n // scale or `uuid` case. The engine compares every proposed pair itself.\n // Text is byte-comparable by default because every collation postgres\n // creates is deterministic unless it was explicitly built with\n // `deterministic = false`: 'e' and 'E' stayed two rows on a default-collation\n // column. `numeric` is the exception the ORM cannot see from the encoded\n // value: '1.0' and '1.00' are one row.\n conflictKeyEquality: {\n foldingScalars: [\"Decimal\"],\n textIsBinaryByDefault: true,\n duplicatesInOneStatement: \"reject\",\n },\n excludedRowRef: { form: \"keyword\", name: \"excluded\" },\n doNothingForm: \"onConflictDoNothing\",\n insensitiveLike: \"ilike\",\n // Postgres `=`/`LIKE` are already byte-sensitive — strict mode is a no-op.\n strictMatchStrategy: \"native\",\n greatestForm: \"native\",\n orderByNullsMode: \"native\",\n offsetRequiresLimit: null,\n likeEscapeClause: null,\n jsonPathMode: \"operators\",\n supportedJsonOps: [\n \"equals\",\n \"string_contains\",\n \"string_starts_with\",\n \"string_ends_with\",\n \"array_contains\",\n \"array_starts_with\",\n \"array_ends_with\",\n ],\n // Json params bind as TEXT and the server parses (`$n::text::jsonb`):\n // OID-typed drivers (bun:sql) would re-serialize a bare jsonb-slot param\n // and double-encode the document (JsonParamCell, ast.ts).\n jsonParamCast: \"::text::jsonb\",\n valueCastTypes: Object.freeze({ String: \"TEXT\", Boolean: \"BOOLEAN\", Int: \"INTEGER\", BigInt: \"BIGINT\", Float: \"DOUBLE PRECISION\", Decimal: \"NUMERIC\", DateTime: \"TIMESTAMPTZ\", Json: \"JSONB\", Bytes: \"BYTEA\" }),\n lastInsertIdSql: null,\n // All four strengths and all three wait policies parse and behave on\n // PostgreSQL 18.6 and on PGlite 0.5.4 (PostgreSQL 18.3) — probed, not assumed.\n rowLockSyntax: {\n strengths: Object.freeze({\n update: \"FOR UPDATE\",\n noKeyUpdate: \"FOR NO KEY UPDATE\",\n share: \"FOR SHARE\",\n keyShare: \"FOR KEY SHARE\",\n }),\n wait: Object.freeze({ wait: \"\", nowait: \" NOWAIT\", skipLocked: \" SKIP LOCKED\" }),\n },\n // Transaction-scoped only. The session-scoped family (pg_advisory_lock) is\n // deliberately absent: on a pooled connection its lock outlives the caller.\n advisoryLockFunctions: {\n exclusive: Object.freeze({\n wait: \"pg_catalog.pg_advisory_xact_lock\",\n nowait: \"pg_catalog.pg_try_advisory_xact_lock\",\n }),\n shared: Object.freeze({\n wait: \"pg_catalog.pg_advisory_xact_lock_shared\",\n nowait: \"pg_catalog.pg_try_advisory_xact_lock_shared\",\n }),\n keyCast: Object.freeze({ single: \"::bigint\", pair: \"::int4\" }),\n },\n rowDefaultKeyword: true,\n bulkInsertForm: \"unnest\",\n emptyInsert: { form: \"defaultValues\", conflictClause: true },\n // Data-modifying CTEs (`WITH s AS (UPDATE … RETURNING …) SELECT …`) — one\n // snapshot, one atomic statement; PGlite runs the same engine.\n statementChain: \"dataModifyingCte\",\n paramBudget: 30000,\n\n // A real `boolean` type — `true`/`false` are the literals it stores.\n booleanLiteral: { true: \"true\", false: \"false\" },\n\n quoteIdent({ name }) {\n return `\"${assertNoNul({ name }).replaceAll('\"', '\"\"')}\"`;\n },\n // `standard_conforming_strings` has been on by default since postgres 9.1,\n // so a backslash is an ordinary character and only the quote is doubled.\n quoteStringLiteral({ value }) {\n return `'${value.replaceAll(\"'\", \"''\")}'`;\n },\n placeholder({ index }) {\n return `$${index}`;\n },\n jsonTextProjection({ expression }): string {\n return `${expression}::text`;\n },\n renderDbNow({ offsetSeconds, collector }) {\n if (offsetSeconds === 0) return \"now()\";\n return `(now() + make_interval(secs => ${collector.add(offsetSeconds)}))`;\n },\n};\n",
@@ -46,6 +46,7 @@
46
46
  "/**\n * Dialect registry: the one place a `Dialect` name becomes a `SqlDialect`.\n *\n * Runtime and adapters resolve through this map so nobody re-implements the\n * lookup (and nobody can quietly forget a dialect — the Record type is total).\n */\n\nimport type { Dialect } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport { postgresDialect } from \"./postgres.ts\";\nimport { sqliteDialect } from \"./sqlite.ts\";\nimport { mysqlDialect } from \"./mysql.ts\";\n\nexport const SQL_DIALECTS: Readonly<Record<Dialect, SqlDialect>> = {\n postgres: postgresDialect,\n sqlite: sqliteDialect,\n mysql: mysqlDialect,\n};\n\n/** The SQL dialect a dialect name selects. */\nexport function getSqlDialect(params: { dialect: Dialect }): SqlDialect {\n return SQL_DIALECTS[params.dialect];\n}\n",
47
47
  "/**\n * Key-list membership (`SqlExpr` `keyList`, the public `where: { IN }`):\n * the postgres element type each member's array binds as.\n *\n * Postgres compares `\"col\" = $n` with the parameter typed as the column's\n * type WITHOUT its modifier (measured on postgres 18.6: `timestamptz(3) =\n * '…00.1234'` matches nothing, `numeric(10,2) = '1.234'` matches nothing,\n * `varchar(3) = 'abcd'` matches nothing). The unnest form must compare the\n * same way, so every member binds as `$n::<base type>[]`: a `timestamptz(3)[]`\n * cast would round `.1234` onto the stored `.123` and match a row `=` does not.\n * The base type also keeps the column's own operator and index: `bpchar` for\n * `char(n)` (pad-insensitive like `=`), `citext` (case-insensitive like `=`;\n * a `text[]` member would compare case-sensitively), the native enum's own\n * type, and text collations resolve to the column's collation, as for `=`.\n */\n\nimport { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { ScalarType } from \"@vibeorm/schema\";\nimport type { KeyListMember } from \"./ast.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\n\n/** Canonical element type per scalar (the column type when no `@db.*` type is declared). */\nconst SCALAR_ELEMENT_TYPES: Readonly<Record<ScalarType, string | null>> = Object.freeze({\n String: \"text\",\n Boolean: \"bool\",\n Int: \"int4\",\n BigInt: \"int8\",\n Float: \"float8\",\n Decimal: \"numeric\",\n DateTime: \"timestamptz\",\n // Json has no equality operator a key can use; the runtime refuses it first.\n Json: null,\n Bytes: \"bytea\",\n});\n\n/**\n * Declared native base name (lowercase, spaces and modifier removed) → element\n * type. Every Prisma postgres `@db.*` type a key field can carry, plus the\n * catalog spellings `db pull` and hand-written schemas use.\n */\nconst NATIVE_ELEMENT_TYPES: Readonly<Record<string, string>> = Object.freeze({\n text: \"text\",\n varchar: \"varchar\",\n charactervarying: \"varchar\",\n char: \"bpchar\",\n character: \"bpchar\",\n bpchar: \"bpchar\",\n uuid: \"uuid\",\n citext: \"citext\",\n xml: \"xml\",\n inet: \"inet\",\n money: \"money\",\n // Quoted: an unquoted `bit` is the SQL-standard `bit(1)` and refuses `101`.\n bit: \"\\\"bit\\\"\",\n varbit: \"varbit\",\n bitvarying: \"varbit\",\n smallint: \"int2\",\n int2: \"int2\",\n integer: \"int4\",\n int: \"int4\",\n int4: \"int4\",\n bigint: \"int8\",\n int8: \"int8\",\n oid: \"oid\",\n real: \"float4\",\n float4: \"float4\",\n doubleprecision: \"float8\",\n double: \"float8\",\n float8: \"float8\",\n decimal: \"numeric\",\n numeric: \"numeric\",\n boolean: \"bool\",\n bool: \"bool\",\n timestamp: \"timestamp\",\n timestampwithouttimezone: \"timestamp\",\n timestamptz: \"timestamptz\",\n timestampwithtimezone: \"timestamptz\",\n date: \"date\",\n time: \"time\",\n timewithouttimezone: \"time\",\n timetz: \"timetz\",\n timewithtimezone: \"timetz\",\n bytea: \"bytea\",\n});\n\n/**\n * The postgres element type a key-list member's array binds as, or\n * `undefined` when the member has none (Json, or a native type this list does\n * not know). Never throws: a caller deciding whether a key list CAN carry a\n * member (the automatic OR rewrite) asks here; {@link postgresKeyListElementType}\n * is the throwing form the renderer uses.\n */\nexport function postgresKeyListElementTypeOf(params: { dialect: SqlDialect; member: KeyListMember }): string | undefined {\n const { dialect, member } = params;\n if (member.type === \"Enum\") {\n if (member.enumType === undefined) return \"text\";\n const name = dialect.quoteIdent({ name: member.enumType.name });\n return member.enumType.namespace === undefined ? name : `${dialect.quoteIdent({ name: member.enumType.namespace })}.${name}`;\n }\n const native = member.nativeType === undefined\n ? undefined\n : NATIVE_ELEMENT_TYPES[member.nativeType.toLowerCase().replace(/\\([^)]*\\)/g, \"\").replace(/\\s+/g, \"\")];\n const type = member.nativeType === undefined ? SCALAR_ELEMENT_TYPES[member.type] : native;\n return type === null ? undefined : type;\n}\n\n/**\n * The postgres element type a key-list member's array binds as\n * (`$n::<type>[]`), derived from the column's declared type facts.\n *\n * @throws VibeError `VIBE_UNSUPPORTED_CAPABILITY` for a member whose type has\n * no equality a key can use (Json) or a native type this list does not know.\n */\nexport function postgresKeyListElementType(params: { dialect: SqlDialect; member: KeyListMember }): string {\n const { dialect, member } = params;\n const type = postgresKeyListElementTypeOf({ dialect, member });\n if (type === undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `the key-list filter (IN) on a ${member.type}${member.nativeType === undefined ? \"\" : ` @db.${member.nativeType}`} member`,\n hint: \"IN binds every member as a typed array; filter this field with equality inside OR instead\",\n });\n }\n return type;\n}\n\n/**\n * Whether a key list must bind its rows as a row-value list of UNTYPED\n * parameters, `(a, b) IN (($1, $2), …)`, instead of typed arrays on the\n * `unnest` strategy: some member is a `DateTime` without a declared native\n * type. Its element type would be `timestamptz`, but such a field may sit on\n * a zone-less `timestamp(3)` column (a Prisma-created database;\n * docs/dialect-notes.md \"DateTime without time zone on postgres\"), where\n * `timestamp = timestamptz` converts the column through the session TimeZone\n * and matches other rows than `\"col\" = $n` (an untyped parameter the server\n * types from the column). The row-value list keeps that typing; PostgreSQL\n * plans it like the OR of conjunctions, so its planning grows with the list.\n * Shared by the renderer and the runtime's render-cache walk.\n */\nexport function keyListBindsUntypedRows(params: { members: readonly KeyListMember[] }): boolean {\n return params.members.some((member) => member.type === \"DateTime\" && member.nativeType === undefined);\n}\n\n// ─── Bulk insert (`InsertStatement.unnest`) ───────────────────────────\n\n/**\n * The cast after a bulk-insert column's array placeholder (`$n::<cast>[]`),\n * or `undefined` when the column has none and the insert must keep VALUES.\n * Never throws: the query builder asks here while deciding admission.\n *\n * Every type the key list knows binds its BASE type, exactly as above — the\n * INSERT's assignment then applies the column's modifier (length, precision,\n * rounding) the way it does for a VALUES parameter. Json is the one addition:\n * it binds through a text slot, `text::jsonb` (`text::json` for `@db.Json`),\n * because PostgreSQL has no assignment cast from text to jsonb and bun:sql's\n * named statements would JSON-encode pre-encoded text bound to a jsonb slot\n * (the `JsonParamCell` rule, per element).\n */\nexport function postgresBulkInsertArrayCastOf(params: { dialect: SqlDialect; member: KeyListMember }): string | undefined {\n const { dialect, member } = params;\n if (member.type === \"Json\") return member.nativeType?.trim().toLowerCase() === \"json\" ? \"text::json\" : \"text::jsonb\";\n return postgresKeyListElementTypeOf({ dialect, member });\n}\n\n/**\n * The throwing form of {@link postgresBulkInsertArrayCastOf}, for the renderer.\n *\n * @throws VibeError `VIBE_UNSUPPORTED_CAPABILITY` for a native type the\n * bulk-insert form does not know.\n */\nexport function postgresBulkInsertArrayCast(params: { dialect: SqlDialect; member: KeyListMember }): string {\n const { dialect, member } = params;\n const cast = postgresBulkInsertArrayCastOf({ dialect, member });\n if (cast === undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `a bulk insert binding a ${member.type}${member.nativeType === undefined ? \"\" : ` @db.${member.nativeType}`} column as a typed array`,\n hint: \"the query builder keeps VALUES for this column type\",\n });\n }\n return cast;\n}\n",
48
48
  "import { localDateCheckName } from \"@vibeorm/schema\";\nimport type { CheckIR } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\n\n/** The single owned SQLite calendar/domain CHECK; native DATE dialects need no marker. */\nexport function renderLocalDateCheck({ dialect, table, column }: {\n readonly dialect: SqlDialect;\n readonly table: string;\n readonly column: string;\n}): CheckIR | undefined {\n if (dialect.name !== \"sqlite\") return undefined;\n const quoted = dialect.quoteIdent({ name: column });\n // The lower bound is NULL-safe and refuses SQLite's otherwise valid year zero.\n return {\n name: localDateCheckName({ table, column }),\n expression: `${quoted} IS date(${quoted}) AND (${quoted} IS NULL OR ${quoted} >= ${dialect.quoteStringLiteral({ value: \"0001-01-01\" })})`,\n };\n}\n",
49
+ "import { DATE_TRUNCATION_UNITS, VibeError, internalError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { DateTruncation } from \"./ast.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\n\n// ─── Calendar truncation (groupBy date keys) ──────────────────────\n\n/**\n * The characters a time-zone name may hold: a leading letter, then letters,\n * digits, `_`, `+`, `-` and `/`, at most 64 characters in all. Every IANA name\n * (`Europe/Oslo`, `America/Argentina/Buenos_Aires`, `Etc/GMT+1`) and `UTC`\n * fit. The name renders as an SQL string literal (a bind parameter inside a\n * GROUP BY key would not match the projection's), so this guard is what keeps\n * caller text out of the SQL grammar. Whether the zone EXISTS is the server's\n * decision: PostgreSQL refuses an unknown name with SQLSTATE 22023 (`time zone\n * \"…\" not recognized`) when the statement runs. JavaScript's `Intl` list is\n * not consulted, because its aliases differ from PostgreSQL's.\n */\nconst TIME_ZONE_NAME: RegExp = /^[A-Za-z][A-Za-z0-9_+\\-/]{0,63}$/;\n\n/** Is this value a time-zone name the renderer will spell as a literal? (See {@link TIME_ZONE_NAME}.) */\nexport function isTimeZoneName(params: { readonly value: unknown }): params is { readonly value: string } {\n return typeof params.value === \"string\" && TIME_ZONE_NAME.test(params.value);\n}\n\n/**\n * The start of the period that holds `reference`'s value, in the column's own\n * SQL type, so the field's codec decodes it unchanged:\n *\n * - `timestamptz` → `date_trunc('day', \"col\", 'Europe/Oslo')` — the 3-argument\n * form (PostgreSQL 12 or later) truncates in the named zone, never in the\n * session's `TimeZone`;\n * - `timestamp` (zone-less, UTC wall-clock by contract) →\n * `(date_trunc('day', \"col\" AT TIME ZONE 'UTC', 'Europe/Oslo') AT TIME ZONE 'UTC')`.\n *\n * The unit and the zone are literals, so every site of one key (projection,\n * GROUP BY, ORDER BY) repeats the identical text and binds no parameter.\n */\nexport function renderDateTruncation(params: { readonly dialect: SqlDialect; readonly reference: string; readonly truncation: DateTruncation }): string {\n const { dialect, reference, truncation } = params;\n if (!dialect.capabilities.dateTruncation) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a truncated groupBy key ({ field, truncate, timeZone })\",\n hint: \"only PostgreSQL and PGlite truncate a timestamp in a named time zone — group by the plain field and bucket the rows in code instead\",\n });\n }\n if (!DATE_TRUNCATION_UNITS.includes(truncation.unit)) {\n throw internalError({ message: `unknown date truncation unit ${JSON.stringify(truncation.unit)}` });\n }\n if (!isTimeZoneName({ value: truncation.timeZone })) {\n throw new VibeError({\n code: \"VIBE_VALIDATION\",\n message: `time zone ${JSON.stringify(truncation.timeZone)} is not a time-zone name — use an IANA name such as \"Europe/Oslo\" or \"UTC\"`,\n meta: { timeZone: truncation.timeZone },\n });\n }\n const unit = dialect.quoteStringLiteral({ value: truncation.unit });\n const zone = dialect.quoteStringLiteral({ value: truncation.timeZone });\n switch (truncation.storage) {\n case \"timestamptz\":\n return `date_trunc(${unit}, ${reference}, ${zone})`;\n case \"timestamp\":\n return `(date_trunc(${unit}, ${reference} AT TIME ZONE 'UTC', ${zone}) AT TIME ZONE 'UTC')`;\n default:\n throw internalError({ message: `unknown date truncation storage ${JSON.stringify(truncation.storage)}` });\n }\n}\n",
49
50
  "import { VibeError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { GeneratedColumnIR } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { renderPostgresGeneratedColumnClause } from \"./dialects/postgres-generated-columns.ts\";\nimport { renderMysqlGeneratedColumnClause } from \"./dialects/mysql-generated-columns.ts\";\nimport { renderSqliteGeneratedColumnClause } from \"./dialects/sqlite-generated-columns.ts\";\n\n/** SQL helper name for the canonical stored generation declaration. */\nexport type GeneratedColumnDeclaration = GeneratedColumnIR;\n\n/** Source evidence; virtual storage is reported for the caller's admission check. */\nexport type ExtractedGeneratedColumn = {\n readonly expression: string;\n readonly storage: \"stored\" | \"virtual\";\n readonly columnSql: string;\n /** Declaration prefix, including any type/charset/collation/nullability qualifiers. */\n readonly typeSql: string;\n};\n\n/** Render trusted physical SQL without interpreting or rewriting its expression. */\nexport function renderGeneratedColumnClause({ dialect, generated }: {\n readonly dialect: SqlDialect;\n readonly generated: GeneratedColumnDeclaration;\n}): string {\n if (!(\"generatedColumns\" in dialect.capabilities) || dialect.capabilities.generatedColumns !== true) {\n throw unsupportedCapability({ dialect: dialect.name, feature: \"generatedColumns\" });\n }\n if (generated.storage !== \"stored\") {\n throw unsupportedCapability({ dialect: dialect.name, feature: \"virtualGeneratedColumns\" });\n }\n if (typeof generated.expression !== \"string\" || generated.expression.trim().length === 0 || generated.expression.includes(\"\\0\")) {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: \"A generated column requires non-empty, NUL-free SQL\", meta: { reason: \"generated-expression-invalid\" } });\n }\n switch (dialect.name) {\n case \"postgres\": return renderPostgresGeneratedColumnClause({ generated });\n case \"mysql\": return renderMysqlGeneratedColumnClause({ generated });\n case \"sqlite\": return renderSqliteGeneratedColumnClause({ generated });\n }\n}\n",
50
51
  "import { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { GeneratedColumnDeclaration } from \"../generated-columns.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\n\n/** PostgreSQL stored syntax; the public dispatcher performs declaration admission. */\nexport function renderPostgresGeneratedColumnClause({ generated }: {\n readonly generated: GeneratedColumnDeclaration;\n}): string {\n return `GENERATED ALWAYS AS (${generated.expression}) STORED`;\n}\n\n/** The migration owner creates the desired base context inside the private savepoint. */\nexport type PostgresGeneratedColumnProbe =\n | { readonly operation: \"savepoint\" | \"rollback\" | \"release\"; readonly savepoint: string }\n | { readonly operation: \"add\"; readonly table: QualifiedSqlName; readonly column: string; readonly definition: string };\n\n/** Render pinned-session scratch statements; this helper never executes or manages a session. */\nexport function renderPostgresGeneratedColumnProbe({ dialect, probe }: {\n readonly dialect: SqlDialect;\n readonly probe: PostgresGeneratedColumnProbe;\n}): RenderedQuery {\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"rollbackGeneratedColumnProbe\" });\n const q = ({ name }: { readonly name: string }): string => dialect.quoteIdent({ name });\n let text: string;\n switch (probe.operation) {\n case \"savepoint\": text = `SAVEPOINT ${q({ name: probe.savepoint })}`; break;\n case \"rollback\": text = `ROLLBACK TO SAVEPOINT ${q({ name: probe.savepoint })}`; break;\n case \"release\": text = `RELEASE SAVEPOINT ${q({ name: probe.savepoint })}`; break;\n case \"add\": text = `ALTER TABLE ${q({ name: probe.table.namespace })}.${q({ name: probe.table.name })} ADD COLUMN ${q({ name: probe.column })} ${probe.definition}`; break;\n }\n return { text, values: [], returning: \"none\" };\n}\n\n/** Approved stored-generated to ordinary conversion, retaining the present stored values. */\nexport function renderPostgresDropGeneratedExpression({ dialect, table, column }: {\n readonly dialect: SqlDialect;\n readonly table: QualifiedSqlName;\n readonly column: string;\n}): RenderedQuery {\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"dropGeneratedExpression\" });\n return { text: `ALTER TABLE ${dialect.quoteIdent({ name: table.namespace })}.${dialect.quoteIdent({ name: table.name })} ALTER COLUMN ${dialect.quoteIdent({ name: column })} DROP EXPRESSION`, values: [], returning: \"none\" };\n}\n",
51
52
  "import { VibeError, internalError, normalizeRowRules, rowRuleGateField, rowRuleIdentities, rowRuleProtectedFields, rowRuleShapeIssue, rowRuleTriggerName, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { FieldIR, ModelIR, QualifiedSqlName, RowRuleEvent, RowRuleIR, SchemaIR, SqlObjectIdentity } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { renderPostgresRowRule } from \"./dialects/postgres-row-rules.ts\";\nimport { renderSqliteRowRule } from \"./dialects/sqlite-row-rules.ts\";\nimport { renderMysqlRowRule } from \"./dialects/mysql-row-rules.ts\";\n\n/** Finalized row-only inputs for the two per-event trigger renderers; not a SQL root export. */\nexport type EventRowRuleContext = {\n readonly model: string;\n readonly table: QualifiedSqlName;\n readonly rule: RowRuleIR;\n readonly triggers: readonly {\n readonly event: RowRuleEvent;\n readonly identity: { readonly kind: \"trigger\"; readonly table: QualifiedSqlName; readonly name: string };\n }[];\n readonly protectedFields: readonly FieldIR[];\n readonly gateField?: FieldIR;\n /** MySQL only: keep a re-created trigger at its earlier action-order position. */\n readonly placement?: Readonly<Record<string, RowRuleTriggerPlacement>>;\n};\n\n/**\n * MySQL `FOLLOWS`/`PRECEDES` position for one rule trigger, keyed by its event\n * trigger name. Disposable references use it to re-create a trigger where it was,\n * so a verification replay never changes the action order it then compares.\n */\nexport type RowRuleTriggerPlacement = { readonly follows: string } | { readonly precedes: string };\n\n/** Parameter-free rule DDL; each function body remains one complete statement. */\nexport type RowRuleStatement = {\n readonly text: string;\n readonly values: readonly unknown[];\n};\n\n/** Dialect-neutral physical output; later dialects may emit several triggers and no function. */\nexport type RenderedRowRule = {\n readonly identities: readonly SqlObjectIdentity[];\n /** Create objects after the final table shape exists, in dependency order. */\n readonly create: readonly RowRuleStatement[];\n /** Drop objects before invalidating table changes, in reverse dependency order. */\n readonly drop: readonly RowRuleStatement[];\n /** Logical fields, not observed catalog dependencies; generated fields are excluded. */\n readonly protectedFields: readonly string[];\n /** OLD's non-NULL activation field; it is also protected against later changes. */\n readonly gateField?: string;\n};\n\n/** Render a canonical declaration against the complete finalized model and authored generated-column evidence. */\nexport function renderRowRule({ schema, model, rule, dialect, placement }: {\n readonly schema: SchemaIR;\n readonly model: ModelIR;\n readonly rule: RowRuleIR;\n readonly dialect: SqlDialect;\n /** MySQL only; other engines have no trigger-order clause. */\n readonly placement?: Readonly<Record<string, RowRuleTriggerPlacement>>;\n}): RenderedRowRule {\n const issue = rowRuleShapeIssue({ value: rule });\n if (issue !== undefined) {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: issue, meta: { model: model.name } });\n }\n if (placement !== undefined && Object.keys(placement).length > 0 && dialect.name !== \"mysql\") throw unsupportedCapability({ dialect: dialect.name, feature: \"rowRuleTriggerPlacement\" });\n const normalized = normalizeRowRules({ schema, model, rules: [rule], dialect: dialect.name })[0]!;\n switch (dialect.name) {\n case \"postgres\": {\n const objects = rowRuleIdentities({ schema, model, rule: normalized, dialect: dialect.name });\n const functionIdentity = objects.find((object) => object.role === \"function\")?.identity;\n const triggerIdentity = objects.find((object) => object.role === \"trigger\")?.identity;\n if (functionIdentity?.kind !== \"function\" || triggerIdentity?.kind !== \"trigger\") throw internalError({ message: \"PostgreSQL row rules own one function and one trigger\", meta: { model: model.name, rule: normalized.name } });\n const gate = rowRuleGateField({ rule: normalized });\n const gateField = gate === undefined ? undefined : model.fields.find((field) => field.name === gate);\n return renderPostgresRowRule({\n dialect,\n context: {\n model: model.name, table: triggerIdentity.table, rule: normalized,\n functionIdentity, triggerIdentity: { kind: \"trigger\", table: triggerIdentity.table, name: triggerIdentity.name },\n protectedFields: rowRuleProtectedFields({ schema, model, rule: normalized }),\n ...(gateField === undefined ? {} : { gateField }),\n },\n });\n }\n case \"sqlite\":\n case \"mysql\": {\n const objects = rowRuleIdentities({ schema, model, rule: normalized, dialect: dialect.name });\n const triggers = objects.map(({ role, identity }): EventRowRuleContext[\"triggers\"][number] => {\n if (role !== \"trigger\" || identity.kind !== \"trigger\") throw internalError({ message: \"Event row rules own only triggers\", meta: { model: model.name, rule: normalized.name } });\n const event = ([\"update\", \"delete\"] as const).find((event) => identity.name === rowRuleTriggerName({ rule: normalized, event }));\n if (event === undefined) throw internalError({ message: \"Row-rule identity has no declared event\", meta: { model: model.name, rule: normalized.name, trigger: identity.name } });\n return { event, identity: { kind: \"trigger\", table: identity.table, name: identity.name } };\n });\n const table = triggers[0]?.identity.table;\n if (table === undefined) throw internalError({ message: \"Event row rules require at least one trigger\", meta: { model: model.name, rule: normalized.name } });\n const gate = rowRuleGateField({ rule: normalized });\n const gateField = gate === undefined ? undefined : model.fields.find((field) => field.name === gate);\n const context: EventRowRuleContext = {\n model: model.name, table, rule: normalized, triggers,\n protectedFields: rowRuleProtectedFields({ schema, model, rule: normalized }),\n ...(gateField === undefined ? {} : { gateField }),\n ...(placement === undefined ? {} : { placement }),\n };\n return dialect.name === \"sqlite\" ? renderSqliteRowRule({ dialect, context }) : renderMysqlRowRule({ dialect, context });\n }\n }\n}\n",
@@ -57,7 +58,7 @@
57
58
  "/**\n * PostgreSQL query-diagnostic SQL (EPIC 5).\n *\n * Two kinds of text live here and nowhere else:\n *\n * - the `EXPLAIN` wrapper, which prefixes an already-rendered statement and\n * keeps its placeholders and its parameters intact — a plan is never taken\n * over SQL with values inlined into the text;\n * - read-only catalog and statistics reads used to interpret a plan.\n *\n * What this module deliberately cannot express: `CREATE EXTENSION`,\n * `pg_stat_statements_reset()`, `ALTER SYSTEM`, `SET` outside a caller's own\n * transaction, and `CREATE INDEX`. Diagnostics observe a server; they never\n * change one.\n */\n\nimport { VibeError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\n\n// ─── EXPLAIN ──────────────────────────────────────────────────────\n\n/**\n * `EXPLAIN` options. `analyze` EXECUTES the statement — the runtime gates it\n * behind an explicit confirmation, refuses writes and multi-statement text,\n * and warns; the renderer only writes the text it is asked for.\n */\nexport type PostgresExplainOptions = {\n /** Run the statement and report observed rows and milliseconds. EXECUTES SQL. */\n readonly analyze?: boolean;\n /** Buffer accounting; only meaningful once the statement actually ran. */\n readonly buffers?: boolean;\n readonly verbose?: boolean;\n readonly settings?: boolean;\n};\n\n/**\n * Wrap a rendered statement in `EXPLAIN (…)`. Option order is fixed so the\n * text is stable and reviewable; `FORMAT JSON` is always present because the\n * parser reads the structured form, never the human text.\n */\nexport function renderPostgresExplain(params: {\n dialect: SqlDialect;\n query: RenderedQuery;\n options?: PostgresExplainOptions;\n}): RenderedQuery {\n const { dialect, query, options } = params;\n requirePostgres({ dialect, feature: \"query plan inspection (EXPLAIN)\" });\n const parts: string[] = [];\n if (options?.analyze === true) parts.push(\"ANALYZE\");\n parts.push(\"FORMAT JSON\");\n if (options?.verbose === true) parts.push(\"VERBOSE\");\n if (options?.buffers === true) parts.push(\"BUFFERS\");\n if (options?.settings === true) parts.push(\"SETTINGS\");\n return { text: `EXPLAIN (${parts.join(\", \")}) ${query.text}`, values: [...query.values], returning: \"none\" };\n}\n\n// ─── Read-only workload and catalog reads ─────────────────────────\n\n/** The closed set of read-only diagnostic reads. Every one of them is a SELECT. */\nexport type PostgresWorkloadQuery =\n | \"planContext\"\n | \"statementExtension\"\n | \"statementInfo\"\n | \"statementSnapshot\"\n | \"indexes\"\n | \"tableStats\"\n | \"sessionBegin\"\n | \"sessionReadOnly\"\n | \"sessionCommit\"\n | \"sessionRollback\"\n | \"setContext\";\n\n/** The exact SQL text of every read-only diagnostic read, for statement-level routing in tests. */\nexport const POSTGRES_DIAGNOSTIC_SQL: Readonly<Record<PostgresWorkloadQuery, string>> = Object.freeze({\n planContext: `SELECT current_user::text AS \"currentUser\", session_user::text AS \"sessionUser\", r.rolsuper AS \"superuser\", r.rolbypassrls AS \"bypassRls\", pg_catalog.current_setting('server_version_num') AS \"serverVersionNum\", pg_catalog.current_database()::text AS \"database\" FROM pg_catalog.pg_roles r WHERE r.rolname = current_user`,\n\n statementExtension: `SELECT (SELECT e.extversion FROM pg_catalog.pg_extension e WHERE e.extname = 'pg_stat_statements') AS \"installedVersion\", EXISTS (SELECT 1 FROM pg_catalog.pg_available_extensions a WHERE a.name = 'pg_stat_statements') AS \"available\", (SELECT n.nspname::text FROM pg_catalog.pg_extension e JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace WHERE e.extname = 'pg_stat_statements') AS \"schema\", pg_catalog.current_setting('server_version_num') AS \"serverVersionNum\", pg_catalog.pg_has_role(current_user, 'pg_read_all_stats', 'MEMBER') AS \"readAllStats\", current_user::text AS \"currentUser\"`,\n\n // %SCHEMA% is substituted with dialect.quoteIdent — never with a parameter:\n // the extension's schema is an identifier, and PostgreSQL takes no parameter\n // in a FROM clause.\n statementInfo: `SELECT i.stats_reset::text AS \"statsReset\" FROM %SCHEMA%.pg_stat_statements_info i`,\n\n statementSnapshot: `SELECT s.queryid::text AS \"queryId\", s.query AS \"query\", s.calls AS \"calls\", s.total_exec_time AS \"totalExecTimeMs\", s.mean_exec_time AS \"meanExecTimeMs\", s.min_exec_time AS \"minExecTimeMs\", s.max_exec_time AS \"maxExecTimeMs\", s.rows AS \"rows\", s.shared_blks_hit AS \"sharedBlocksHit\", s.shared_blks_read AS \"sharedBlocksRead\", s.temp_blks_read AS \"tempBlocksRead\", s.temp_blks_written AS \"tempBlocksWritten\" FROM %SCHEMA%.pg_stat_statements s JOIN pg_catalog.pg_database d ON d.oid = s.dbid WHERE d.datname = pg_catalog.current_database() ORDER BY s.total_exec_time DESC LIMIT %LIMIT%`,\n\n indexes: `SELECT i.relname::text AS \"index\", pg_catalog.pg_get_indexdef(x.indexrelid) AS \"definition\", x.indisunique AS \"unique\", x.indisprimary AS \"primary\", x.indisvalid AS \"valid\", pg_catalog.pg_relation_size(x.indexrelid) AS \"indexBytes\" FROM pg_catalog.pg_index x JOIN pg_catalog.pg_class c ON c.oid = x.indrelid JOIN pg_catalog.pg_class i ON i.oid = x.indexrelid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE n.nspname = %SCHEMA_PARAM% AND c.relname = %TABLE_PARAM% ORDER BY i.relname`,\n\n // Transaction control for a diagnostic session. The plan and the context that\n // shapes it must sit in ONE transaction, and the executing mode runs inside a\n // read-only transaction — defence in depth, NOT a proof of safety (a SELECT\n // can still call a function with side effects).\n sessionBegin: \"BEGIN\",\n sessionReadOnly: \"SET TRANSACTION READ ONLY\",\n sessionCommit: \"COMMIT\",\n sessionRollback: \"ROLLBACK\",\n\n // The same transaction-local settings the client binds for native RLS, with\n // the same `vibeorm.` prefix and the same `is_local = true`: a plan taken\n // under different settings is a plan of a different query.\n setContext: `SELECT pg_catalog.set_config(%KEY%, %VALUE%, true)`,\n\n tableStats: `SELECT c.reltuples::float8 AS \"estimatedRows\", c.relpages::bigint AS \"pages\", pg_catalog.pg_table_size(c.oid) AS \"tableBytes\", c.relrowsecurity AS \"rlsEnabled\", c.relforcerowsecurity AS \"rlsForced\", (SELECT s.last_analyze::text FROM pg_catalog.pg_stat_all_tables s WHERE s.relid = c.oid) AS \"lastAnalyze\", (SELECT s.last_autoanalyze::text FROM pg_catalog.pg_stat_all_tables s WHERE s.relid = c.oid) AS \"lastAutoAnalyze\" FROM pg_catalog.pg_class c JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE n.nspname = %SCHEMA_PARAM% AND c.relname = %TABLE_PARAM%`,\n});\n\n/** Bounds on the workload snapshot; an unbounded diagnostic read is not a diagnostic. */\nexport const POSTGRES_WORKLOAD_LIMITS: { readonly minLimit: number; readonly maxLimit: number } = Object.freeze({\n minLimit: 1,\n maxLimit: 1000,\n});\n\nfunction requirePostgres(params: { dialect: SqlDialect; feature: string }): void {\n if (params.dialect.name !== \"postgres\") {\n throw unsupportedCapability({\n dialect: params.dialect.name,\n feature: params.feature,\n hint: \"plan inspection and workload statistics are PostgreSQL-shaped; portable operation tracing works on every dialect\",\n });\n }\n}\n\n/**\n * Render one read-only diagnostic read. Identifiers (the extension's schema)\n * go through `dialect.quoteIdent`; every value goes through a\n * {@link ParamCollector}, so no caller string is ever concatenated into SQL.\n */\nexport function renderPostgresWorkload(params: {\n dialect: SqlDialect;\n query: PostgresWorkloadQuery;\n /** Extension schema (statementInfo/statementSnapshot) or table schema (indexes/tableStats). */\n schema?: string;\n table?: string;\n limit?: number;\n /** Fully-qualified setting name for `setContext` (the caller applies the prefix). */\n key?: string;\n /** Setting value for `setContext`; `null` binds the empty string, which reads as absent. */\n value?: string | null;\n}): RenderedQuery {\n const { dialect, query, schema, table, limit } = params;\n requirePostgres({ dialect, feature: `the \"${query}\" diagnostic read` });\n const collector = new ParamCollector(dialect);\n let text = POSTGRES_DIAGNOSTIC_SQL[query];\n\n if (query === \"statementInfo\" || query === \"statementSnapshot\") {\n text = text.replace(\"%SCHEMA%\", dialect.quoteIdent({ name: requireArg({ value: schema, name: \"schema\", query }) }));\n }\n if (query === \"statementSnapshot\") {\n const bounded = limit ?? 20;\n if (!Number.isInteger(bounded) || bounded < POSTGRES_WORKLOAD_LIMITS.minLimit || bounded > POSTGRES_WORKLOAD_LIMITS.maxLimit) {\n throw new VibeError({\n code: \"VIBE_CONFIG\",\n message: `workload snapshot limit must be an integer between ${POSTGRES_WORKLOAD_LIMITS.minLimit} and ${POSTGRES_WORKLOAD_LIMITS.maxLimit}, got ${String(limit)}`,\n meta: { limit },\n });\n }\n text = text.replace(\"%LIMIT%\", collector.add(bounded));\n }\n if (query === \"setContext\") {\n text = text\n .replace(\"%KEY%\", collector.add(requireArg({ value: params.key, name: \"key\", query })))\n .replace(\"%VALUE%\", collector.add(params.value ?? \"\"));\n }\n if (query === \"indexes\" || query === \"tableStats\") {\n text = text\n .replace(\"%SCHEMA_PARAM%\", collector.add(requireArg({ value: schema, name: \"schema\", query })))\n .replace(\"%TABLE_PARAM%\", collector.add(requireArg({ value: table, name: \"table\", query })));\n }\n return { text, values: collector.values, returning: \"none\" };\n}\n\nfunction requireArg(params: { value: string | undefined; name: string; query: PostgresWorkloadQuery }): string {\n const { value, name, query } = params;\n if (value === undefined || value.length === 0) {\n throw new VibeError({\n code: \"VIBE_CONFIG\",\n message: `the \"${query}\" diagnostic read requires a ${name}`,\n meta: { query, argument: name },\n });\n }\n return value;\n}\n",
58
59
  "/** PostgreSQL readiness catalog reads and temporary-clone DDL. Runtime owns execution order. */\nimport { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport { NATIVE_RLS } from \"./postgres-rls.ts\";\n\n/** Throwaway policy identity; never installed on a live table by readiness. */\nexport const NATIVE_RLS_PROBE_POLICY: \"vibeorm_probe\" = \"vibeorm_probe\";\n\n/** The eight independent catalog reads, folded into one statement by `catalog`. */\nconst CATALOG_READS: {\n readonly identity: string;\n readonly elevatedRoles: string;\n readonly schemaControl: string;\n readonly tables: string;\n readonly policies: string;\n readonly views: string;\n readonly routines: string;\n readonly triggers: string;\n} = Object.freeze({\n identity: `SELECT current_user::text AS \"currentUser\",\n session_user::text AS \"sessionUser\",\n r.rolsuper AS \"super\",\n r.rolbypassrls AS \"bypassRls\",\n r.rolcreatedb AS \"createDb\",\n r.rolcreaterole AS \"createRole\",\n pg_catalog.current_setting('server_version_num') AS \"serverVersionNum\",\n pg_catalog.pg_backend_pid()::text AS \"backendPid\",\n pg_catalog.pg_postmaster_start_time()::text AS \"instanceStart\",\n (SELECT a.backend_start::text FROM pg_catalog.pg_stat_activity a WHERE a.pid = pg_catalog.pg_backend_pid()) AS \"backendStart\",\n pg_catalog.has_database_privilege(current_user, pg_catalog.current_database(), 'TEMP') AS \"tempPrivilege\"\nFROM pg_catalog.pg_roles r\nWHERE r.rolname = current_user`,\n\n // Membership is the RECURSIVE role graph: pg_has_role(..., 'MEMBER') is true\n // for indirect membership and for NOINHERIT roles the runtime could SET ROLE\n // into. Predefined pg_* roles are flagged wholesale — pg_execute_server_program,\n // pg_read_server_files and pg_write_server_files reach the host even with\n // rolbypassrls = false, and pg_database_owner owns the public schema.\n elevatedRoles: `SELECT r.rolname::text AS \"role\",\n r.rolsuper AS \"super\",\n r.rolbypassrls AS \"bypassRls\",\n r.rolcreaterole AS \"createRole\",\n r.rolcreatedb AS \"createDb\"\nFROM pg_catalog.pg_roles r\nWHERE r.rolname <> current_user\n AND pg_catalog.pg_has_role(current_user, r.oid, 'MEMBER')\n AND (r.rolsuper OR r.rolbypassrls OR r.rolcreaterole OR r.rolcreatedb OR r.rolname LIKE 'pg\\\\_%')\nORDER BY r.rolname`,\n\n // Owning the schema means DROP SCHEMA ... CASCADE reaches every protected\n // table inside it; owning the database reaches the schema.\n schemaControl: `SELECT n.nspname::text AS \"schema\",\n pg_catalog.pg_get_userbyid(n.nspowner)::text AS \"owner\",\n pg_catalog.pg_has_role(current_user, n.nspowner, 'MEMBER') AS \"ownerAccess\",\n EXISTS (\n SELECT 1 FROM pg_catalog.pg_roles r\n WHERE pg_catalog.pg_has_role(current_user, r.oid, 'MEMBER')\n AND pg_catalog.has_schema_privilege(r.oid, n.oid, 'CREATE')\n ) AS \"create\",\n pg_catalog.current_database()::text AS \"database\",\n pg_catalog.pg_get_userbyid(d.datdba)::text AS \"databaseOwner\",\n pg_catalog.pg_has_role(current_user, d.datdba, 'MEMBER') AS \"databaseOwnerAccess\"\nFROM pg_catalog.pg_namespace n\nJOIN pg_catalog.pg_database d ON d.datname = pg_catalog.current_database()\nWHERE n.nspname = $1`,\n\n // ownerAccess covers direct ownership, inherited membership and SET ROLE\n // reach alike. TRUNCATE is checked for every role the runtime can reach,\n // because has_table_privilege(current_user, ...) alone misses a privilege\n // held by a NOINHERIT role the runtime may SET ROLE into.\n tables: `SELECT c.relname::text AS \"table\",\n c.relrowsecurity AS \"rlsEnabled\",\n c.relforcerowsecurity AS \"rlsForced\",\n pg_catalog.pg_get_userbyid(c.relowner)::text AS \"owner\",\n pg_catalog.pg_has_role(current_user, c.relowner, 'MEMBER') AS \"ownerAccess\",\n EXISTS (\n SELECT 1 FROM pg_catalog.pg_roles r\n WHERE pg_catalog.pg_has_role(current_user, r.oid, 'MEMBER')\n AND pg_catalog.has_table_privilege(r.oid, c.oid, 'TRUNCATE')\n ) AS \"truncate\"\nFROM pg_catalog.pg_class c\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname = $1 AND c.relkind IN ('r', 'p')\nORDER BY c.relname`,\n\n policies: `SELECT c.relname::text AS \"table\",\n p.polname::text AS \"name\",\n p.polpermissive AS \"permissive\",\n p.polcmd::text AS \"command\",\n (p.polroles = '{0}'::oid[]) AS \"toPublic\",\n (p.polqual IS NOT NULL) AS \"hasUsing\",\n (p.polwithcheck IS NOT NULL) AS \"hasWithCheck\"\nFROM pg_catalog.pg_policy p\nJOIN pg_catalog.pg_class c ON c.oid = p.polrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname = $1\nORDER BY c.relname, p.polname`,\n\n // Only objects this role can actually reach are reported.\n views: `SELECT n.nspname::text AS \"schema\",\n c.relname::text AS \"name\",\n pg_catalog.pg_get_userbyid(c.relowner)::text AS \"owner\",\n (c.relkind = 'm') AS \"materialized\",\n (COALESCE((\n SELECT o.option_value FROM pg_catalog.pg_options_to_table(c.reloptions) AS o\n WHERE o.option_name = 'security_invoker'\n ), 'false') = 'true') AS \"securityInvoker\"\nFROM pg_catalog.pg_class c\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname NOT IN ('pg_catalog', 'information_schema')\n AND c.relkind IN ('v', 'm')\n AND EXISTS (\n SELECT 1 FROM pg_catalog.pg_roles r\n WHERE pg_catalog.pg_has_role(current_user, r.oid, 'MEMBER')\n AND pg_catalog.has_schema_privilege(r.oid, n.oid, 'USAGE')\n AND (pg_catalog.has_table_privilege(r.oid, c.oid, 'SELECT')\n OR pg_catalog.has_any_column_privilege(r.oid, c.oid, 'SELECT'))\n )\nORDER BY n.nspname, c.relname`,\n\n routines: `SELECT n.nspname::text AS \"schema\",\n p.proname::text AS \"name\",\n pg_catalog.pg_get_userbyid(p.proowner)::text AS \"owner\"\nFROM pg_catalog.pg_proc p\nJOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace\nWHERE n.nspname NOT IN ('pg_catalog', 'information_schema')\n AND p.prosecdef\n AND EXISTS (\n SELECT 1 FROM pg_catalog.pg_roles r\n WHERE pg_catalog.pg_has_role(current_user, r.oid, 'MEMBER')\n AND pg_catalog.has_schema_privilege(r.oid, n.oid, 'USAGE')\n AND pg_catalog.has_function_privilege(r.oid, p.oid, 'EXECUTE')\n )\nORDER BY n.nspname, p.proname`,\n\n triggers: `SELECT c.relname::text AS \"table\",\n t.tgname::text AS \"name\",\n f.proname::text AS \"function\",\n pg_catalog.pg_get_userbyid(f.proowner)::text AS \"owner\",\n f.prosecdef AS \"securityDefiner\"\nFROM pg_catalog.pg_trigger t\nJOIN pg_catalog.pg_class c ON c.oid = t.tgrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nJOIN pg_catalog.pg_proc f ON f.oid = t.tgfoid\nWHERE n.nspname = $1\n AND NOT t.tgisinternal\n AND f.prosecdef\nORDER BY c.relname, t.tgname`,\n});\n\n/** The reads `catalog` folds, in the order their JSON columns appear. */\nexport const RLS_READINESS_CATALOG_KEYS: readonly (\"identity\" | \"elevatedRoles\" | \"schemaControl\" | \"tables\" | \"policies\" | \"views\" | \"routines\" | \"triggers\")[] =\n Object.freeze([\"identity\", \"elevatedRoles\", \"schemaControl\", \"tables\", \"policies\", \"views\", \"routines\", \"triggers\"] as const);\n\n/**\n * One statement, eight result sets. Each subquery body is the single-read SQL\n * VERBATIM: same predicates, same privileges, same live catalog, read on the\n * same connection under the same role. Only the transport changes.\n *\n * `json_agg(...)::text` is deliberate. Drivers disagree about `json` (node-pg\n * parses it into JS values, others hand back the text), and a security flag\n * that arrives as the STRING \"false\" is truthy. Casting to text gives one\n * shape everywhere, which the reader parses itself — so a boolean stays a\n * boolean. `json_agg` over zero rows is NULL, which the reader can tell apart\n * from a value it could not read.\n *\n * A second, free property: the eight facts now share ONE snapshot. Under READ\n * COMMITTED eight separate statements each take their own.\n */\nconst COMPOSITE_CATALOG: string = `SELECT\\n${RLS_READINESS_CATALOG_KEYS.map(\n (key) => ` (SELECT json_agg(t)::text FROM (\\n${CATALOG_READS[key]}\\n ) t) AS \"${key}\"`,\n).join(\",\\n\")}`;\n\n/** Read-only catalog SQL; exported for exact statement routing in adapter tests. */\nexport const RLS_READINESS_SQL: {\n readonly identity: string;\n readonly elevatedRoles: string;\n readonly schemaControl: string;\n readonly tables: string;\n readonly policies: string;\n readonly expressions: string;\n readonly views: string;\n readonly routines: string;\n readonly triggers: string;\n readonly catalog: string;\n readonly readSearchPath: string;\n readonly setSearchPath: string;\n} = Object.freeze({\n identity: CATALOG_READS.identity,\n elevatedRoles: CATALOG_READS.elevatedRoles,\n schemaControl: CATALOG_READS.schemaControl,\n tables: CATALOG_READS.tables,\n policies: CATALOG_READS.policies,\n\n // Both sides of the comparison are deparsed by THIS server, in ONE\n // statement, in one transaction, under the same empty search_path.\n expressions: `SELECT c.relname::text AS \"table\",\n p.polname::text AS \"name\",\n (n.nspname <> $1) AS \"probe\",\n pg_catalog.pg_get_expr(p.polqual, p.polrelid) AS \"using\",\n pg_catalog.pg_get_expr(p.polwithcheck, p.polrelid) AS \"withCheck\"\nFROM pg_catalog.pg_policy p\nJOIN pg_catalog.pg_class c ON c.oid = p.polrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE (n.nspname = $1 AND p.polname = $2)\n OR (c.relnamespace = pg_catalog.pg_my_temp_schema() AND p.polname = $3)\nORDER BY c.relname, p.polname`,\n\n views: CATALOG_READS.views,\n routines: CATALOG_READS.routines,\n triggers: CATALOG_READS.triggers,\n catalog: COMPOSITE_CATALOG,\n\n readSearchPath: `SELECT pg_catalog.current_setting('search_path') AS \"searchPath\"`,\n setSearchPath: `SELECT pg_catalog.set_config('search_path', $1, true)`,\n});\n\n/** The closed set of catalog queries used by readiness. */\nexport type RlsReadinessQuery = keyof typeof RLS_READINESS_SQL;\n\nfunction requireRls(params: { dialect: SqlDialect }): void {\n if (!params.dialect.capabilities.nativeRowLevelSecurity) {\n throw unsupportedCapability({ dialect: params.dialect.name, feature: \"nativeRowLevelSecurity\" });\n }\n}\n\n/** Parameterized catalog read, or transaction-local search-path setting. */\nexport function renderRlsReadinessQuery(params: {\n dialect: SqlDialect;\n query: RlsReadinessQuery;\n searchPath?: string;\n}): RenderedQuery {\n requireRls(params);\n const values = params.query === \"setSearchPath\" ? [params.searchPath ?? \"\"]\n : [NATIVE_RLS.tableSchema, NATIVE_RLS.policyName, NATIVE_RLS_PROBE_POLICY];\n const collector = new ParamCollector(params.dialect);\n const slots = new Map<string, string>();\n const text = RLS_READINESS_SQL[params.query].replace(/\\$(\\d+)/g, (slot, index: string) => {\n let placeholder = slots.get(slot);\n if (placeholder === undefined) {\n placeholder = collector.add(values[Number(index) - 1]);\n slots.set(slot, placeholder);\n }\n return placeholder;\n });\n return { text, values: collector.values, returning: \"none\" };\n}\n\n/** Clone only physical columns/types, on the same backend and with the same table name. */\nexport function renderRlsProbeTable(params: { dialect: SqlDialect; table: string; action: \"create\" | \"drop\" }): RenderedQuery {\n requireRls(params);\n const name = params.dialect.quoteIdent({ name: params.table });\n const schema = params.dialect.quoteIdent({ name: params.action === \"create\" ? NATIVE_RLS.tableSchema : \"pg_temp\" });\n const text = params.action === \"create\"\n ? `CREATE TEMP TABLE ${name} (LIKE ${schema}.${name}) ON COMMIT DROP`\n : `DROP TABLE ${schema}.${name}`;\n return { text, values: [], returning: \"none\" };\n}\n\n/** Save/empty/restore around migration policy DDL without replacing the operator's path. */\nexport function renderRlsPolicyPath(params: { dialect: SqlDialect; stage: \"save\" | \"empty\" | \"restore\" }): RenderedQuery {\n requireRls(params);\n const text = params.stage === \"save\"\n ? \"SELECT pg_catalog.set_config('vibeorm.rls_saved_search_path', pg_catalog.current_setting('search_path'), true)\"\n : params.stage === \"empty\"\n ? \"SELECT pg_catalog.set_config('search_path', '', true)\"\n : \"SELECT pg_catalog.set_config('search_path', pg_catalog.current_setting('vibeorm.rls_saved_search_path'), true)\";\n return { text, values: [], returning: \"none\" };\n}\n",
59
60
  "/** Native RLS text contract. PostgreSQL/PGlite only, with no rewriting fallback. */\nimport { RlsContextError, VibeError, assertNativeRlsAdmission, assertValidSchemaIR, unsupportedCapability, validateRlsContextIR } from \"@vibeorm/schema\";\nimport type { FieldIR, ModelIR, RlsContextIR, RlsContextScalar, SchemaIR } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\n\n/** Managed identity and namespace, shared by migration and readiness checks. */\nexport const NATIVE_RLS: {\n readonly policyName: \"vibeorm_managed\";\n readonly tableSchema: \"public\";\n readonly settingPrefix: \"vibeorm.\";\n readonly parentAlias: \"parent\";\n} = Object.freeze({ policyName: \"vibeorm_managed\", tableSchema: \"public\", settingPrefix: \"vibeorm.\", parentAlias: \"parent\" });\n\nconst COLUMN_TYPES: Readonly<Record<RlsContextScalar, { readonly default: string; readonly native: Readonly<Record<string, string>> }>> = {\n String: { default: \"text\", native: { text: \"text\", varchar: \"varchar\", charactervarying: \"varchar\", uuid: \"uuid\" } },\n Boolean: { default: \"boolean\", native: { boolean: \"boolean\", bool: \"boolean\" } },\n Int: { default: \"integer\", native: { integer: \"integer\", int: \"integer\", int4: \"integer\", smallint: \"smallint\", int2: \"smallint\" } },\n BigInt: { default: \"bigint\", native: { bigint: \"bigint\", int8: \"bigint\" } },\n Float: { default: \"double precision\", native: { doubleprecision: \"double precision\", float8: \"double precision\", real: \"real\", float4: \"real\" } },\n Decimal: { default: \"numeric\", native: { numeric: \"numeric\", decimal: \"numeric\" } },\n DateTime: { default: \"timestamptz\", native: { timestamptz: \"timestamptz\", timestampwithtimezone: \"timestamptz\", timestamp: \"timestamp\", timestampwithouttimezone: \"timestamp\", date: \"date\" } },\n};\n\nfunction requireRls(params: { dialect: SqlDialect }): void {\n if (!params.dialect.capabilities.nativeRowLevelSecurity) {\n throw unsupportedCapability({ dialect: params.dialect.name, feature: \"nativeRowLevelSecurity\" });\n }\n}\n\nfunction identifier(params: { dialect: SqlDialect; name: string }): string {\n if (typeof params.name !== \"string\" || params.name.length === 0 || params.name.includes(\"\\0\") || new TextEncoder().encode(params.name).length > 63) {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: \"Native RLS identifiers must be nonempty PostgreSQL identifiers of at most 63 bytes\" });\n }\n return params.dialect.quoteIdent({ name: params.name });\n}\n\nfunction tableRef(params: { dialect: SqlDialect; table: string; schema?: \"public\" | \"pg_temp\" }): string {\n if (params.schema !== undefined && params.schema !== \"public\" && params.schema !== \"pg_temp\") {\n throw unsupportedCapability({ dialect: params.dialect.name, feature: \"nativeRowLevelSecurity\", hint: \"Only public tables and temporary policy probes are supported\" });\n }\n return `${identifier({ dialect: params.dialect, name: params.schema ?? NATIVE_RLS.tableSchema })}.${identifier({ dialect: params.dialect, name: params.table })}`;\n}\n\nfunction query(params: { text: string; values?: unknown[] }): RenderedQuery {\n return { text: params.text, values: params.values ?? [], returning: \"none\" };\n}\n\n/** ENABLE is one statement; migrate owns transaction/order and pairs it with FORCE. */\nexport function renderRlsEnable(params: { dialect: SqlDialect; table: string }): RenderedQuery {\n requireRls(params);\n return query({ text: `ALTER TABLE ${tableRef(params)} ENABLE ROW LEVEL SECURITY` });\n}\n\n/** FORCE is separate so migration step ordering stays explicit. */\nexport function renderRlsForce(params: { dialect: SqlDialect; table: string }): RenderedQuery {\n requireRls(params);\n return query({ text: `ALTER TABLE ${tableRef(params)} FORCE ROW LEVEL SECURITY` });\n}\n\n/** DISABLE is separate; migrate owns acknowledgement and teardown ordering. */\nexport function renderRlsDisable({ dialect, table }: { dialect: SqlDialect; table: string }): RenderedQuery {\n requireRls({ dialect });\n return query({ text: `ALTER TABLE ${tableRef({ dialect, table })} DISABLE ROW LEVEL SECURITY` });\n}\n\n/** NO FORCE precedes DISABLE when migrate deliberately removes protection. */\nexport function renderRlsNoForce({ dialect, table }: { dialect: SqlDialect; table: string }): RenderedQuery {\n requireRls({ dialect });\n return query({ text: `ALTER TABLE ${tableRef({ dialect, table })} NO FORCE ROW LEVEL SECURITY` });\n}\n\n/** Drop one named policy; migrate owns child-first dependency ordering. */\nexport function renderRlsDropPolicy({ dialect, table, policyName }: {\n dialect: SqlDialect;\n table: string;\n policyName?: string;\n}): RenderedQuery {\n requireRls({ dialect });\n const name = identifier({ dialect, name: policyName ?? NATIVE_RLS.policyName });\n return query({ text: `DROP POLICY ${name} ON ${tableRef({ dialect, table })}` });\n}\n\n/**\n * Context casts use the physical base type, NOT typmods: varchar(n), numeric(p,s)\n * and timestamp(p) casts can truncate/round another identity into an allowed one.\n * Unknown/user-defined casts refuse rather than splice raw nativeType into SQL.\n */\nexport function renderRlsColumnType(params: { dialect: SqlDialect; field: FieldIR }): string {\n requireRls(params);\n const { field } = params;\n const mapping = typeof field.type === \"string\" && Object.hasOwn(COLUMN_TYPES, field.type)\n ? COLUMN_TYPES[field.type as RlsContextScalar] : undefined;\n if (mapping !== undefined && !field.isList && !field.isUnsupported) {\n if (field.nativeType === undefined) return mapping.default;\n const match = /^([a-z][a-z0-9 ]*)(?:\\(\\s*\\d+(?:\\s*,\\s*\\d+)?\\s*\\))?$/i.exec(field.nativeType.trim());\n const base = match?.[1]?.toLowerCase().replace(/\\s+/g, \"\");\n const native = base !== undefined && Object.hasOwn(mapping.native, base) ? mapping.native[base] : undefined;\n if (native !== undefined) return native;\n }\n throw unsupportedCapability({ dialect: params.dialect.name, feature: \"nativeRowLevelSecurity\", hint: `Unsupported physical ownership type on field ${field.name}` });\n}\n\nfunction protectedModel(params: { dialect: SqlDialect; schema: SchemaIR; model: string }): ModelIR {\n requireRls(params);\n assertNativeRlsAdmission({ schema: params.schema, dialect: params.dialect.name });\n assertValidSchemaIR({ schema: params.schema });\n const model = params.schema.models.find((entry) => entry.name === params.model);\n if (model === undefined || model.rls === undefined || model.rls === \"unprotected\") {\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: \"Native RLS policy rendering requires a protected model\", meta: { model: params.model } });\n }\n return model;\n}\n\n/** Desired predicate only, for drift probes; it is NOT server-canonical deparse. */\nexport function renderRlsPredicate(params: { dialect: SqlDialect; schema: SchemaIR; model: string }): string {\n const model = protectedModel(params);\n return predicate({ dialect: params.dialect, schema: params.schema, model });\n}\n\nfunction predicate(params: { dialect: SqlDialect; schema: SchemaIR; model: ModelIR }): string {\n const { dialect, schema, model } = params;\n const rule = model.rls;\n if (rule === \"deny\") return \"false\";\n if (typeof rule === \"object\" && \"where\" in rule) {\n return Object.entries(rule.where).map(([name, ref]) => {\n const field = model.fields.find((entry) => entry.name === name)!;\n const column = identifier({ dialect, name: field.dbName ?? field.name });\n const physicalType = renderRlsColumnType({ dialect, field });\n // Context keys passed structural validation; SQL literals are declarations,\n // never request values. The empty reset sentinel MUST become SQL NULL.\n return `(${column} = NULLIF(current_setting('${NATIVE_RLS.settingPrefix}${ref.context}', true), '')::${physicalType})`;\n }).join(\" AND \");\n }\n if (typeof rule === \"object\" && \"through\" in rule) {\n const relation = model.relations.find((entry) => entry.name === rule.through)!;\n const parent = schema.models.find((entry) => entry.name === relation.targetModel)!;\n const alias = identifier({ dialect, name: NATIVE_RLS.parentAlias });\n const child = identifier({ dialect, name: model.dbName ?? model.name });\n const join = relation.fields!.map((name, index) => {\n const childField = model.fields.find((field) => field.name === name)!;\n const parentField = parent.fields.find((field) => field.name === relation.references![index])!;\n return `(${alias}.${identifier({ dialect, name: parentField.dbName ?? parentField.name })} = ${child}.${identifier({ dialect, name: childField.dbName ?? childField.name })})`;\n }).join(\" AND \");\n return `EXISTS (SELECT 1 FROM ${tableRef({ dialect, table: parent.dbName ?? parent.name })} AS ${alias} WHERE ${join})`;\n }\n throw new VibeError({ code: \"VIBE_SCHEMA_INVALID\", message: \"Native RLS requires a protected policy rule\" });\n}\n\n/** One PERMISSIVE ALL/PUBLIC policy with equal existing/proposed-row checks. */\nexport function renderRlsPolicy(params: {\n dialect: SqlDialect;\n schema: SchemaIR;\n model: string;\n policyName?: string;\n targetSchema?: \"public\" | \"pg_temp\";\n}): RenderedQuery {\n const model = protectedModel(params);\n const expression = predicate({ dialect: params.dialect, schema: params.schema, model });\n const name = identifier({ dialect: params.dialect, name: params.policyName ?? NATIVE_RLS.policyName });\n const table = tableRef({ dialect: params.dialect, table: model.dbName ?? model.name, schema: params.targetSchema });\n return query({ text: `CREATE POLICY ${name} ON ${table} AS PERMISSIVE FOR ALL TO PUBLIC USING (${expression}) WITH CHECK (${expression})` });\n}\n\n/**\n * Every declared setting, parameterized in declaration order and transaction-local.\n *\n * Optional parts travel in the SAME statement (statement-count pass, EPIC 1-2);\n * without them the text is exactly the claims statement:\n * - `role` (PGlite): binds the trusted runtime role FIRST, as {@link renderRlsRole} does;\n * - `readOnly`: switches the transaction to READ ONLY after the claims (`$all` on a\n * verified connection; PostgreSQL accepts this switch at any point of a transaction);\n * - `backend`: reports the backend as `\"backendPid\"` / `\"backendStart\"` text columns,\n * the readiness catalog read's own expressions (adapters that name no connection object).\n *\n * A context with zero keys is accepted only when one of these parts is present.\n */\nexport function renderRlsContext(params: {\n dialect: SqlDialect;\n context: RlsContextIR;\n values: Readonly<Record<string, string | null>>;\n role?: string;\n readOnly?: boolean;\n backend?: boolean;\n}): RenderedQuery {\n requireRls(params);\n const extra = params.role !== undefined || params.readOnly === true || params.backend === true;\n if (validateRlsContextIR({ context: params.context }).length !== 0 || (Object.keys(params.context).length === 0 && !extra) ||\n typeof params.values !== \"object\" || params.values === null || Array.isArray(params.values)) {\n throw new RlsContextError({ reason: \"invalid\" });\n }\n const collector = new ParamCollector(params.dialect);\n const parts: string[] = [];\n if (params.role !== undefined) parts.push(`set_config('role', ${collector.add(runtimeRoleOf({ role: params.role }))}, true)`);\n for (const [key, slot] of Object.entries(params.context)) {\n if (!Object.hasOwn(params.values, key)) throw new RlsContextError({ reason: \"missing\", key });\n const value = params.values[key];\n if ((value === null && !slot.nullable) || (value !== null && (typeof value !== \"string\" || value.length === 0 || value.includes(\"\\0\")))) {\n throw new RlsContextError({ reason: \"invalid\", key });\n }\n parts.push(`set_config(${collector.add(`${NATIVE_RLS.settingPrefix}${key}`)}, ${collector.add(value ?? \"\")}, true)`);\n }\n for (const key of Reflect.ownKeys(params.values)) {\n if (typeof key !== \"string\" || !Object.hasOwn(params.context, key)) throw new RlsContextError({ reason: \"invalid\" });\n }\n if (params.readOnly === true) parts.push(\"set_config('transaction_read_only', 'on', true)\");\n if (params.backend === true) {\n parts.push(\n `pg_catalog.pg_backend_pid()::text AS ${identifier({ dialect: params.dialect, name: \"backendPid\" })}`,\n `(SELECT a.backend_start::text FROM pg_catalog.pg_stat_activity a WHERE a.pid = pg_catalog.pg_backend_pid()) AS ${identifier({ dialect: params.dialect, name: \"backendStart\" })}`,\n );\n }\n return query({ text: `SELECT ${parts.join(\", \")}`, values: collector.values });\n}\n\nfunction runtimeRoleOf(params: { role: string }): string {\n if (typeof params.role !== \"string\" || params.role.trim().length === 0 || params.role.includes(\"\\0\")) {\n throw new VibeError({ code: \"VIBE_CONFIG\", message: \"PGlite native RLS requires a trusted nonempty runtime role name\" });\n }\n return params.role;\n}\n\n/** First transaction statement on eligible PGlite only; server roles are login roles. */\nexport function renderRlsRole(params: { dialect: SqlDialect; role: string }): RenderedQuery {\n requireRls(params);\n const role = runtimeRoleOf({ role: params.role });\n const collector = new ParamCollector(params.dialect);\n return query({ text: `SELECT set_config('role', ${collector.add(role)}, true)`, values: collector.values });\n}\n",
60
- "import { renderSqliteJsonEquality } from \"./dialects/sqlite-json-equality.ts\";\nimport { JSON_TRANSPORT, projectionOutputName } from \"./json-transport.ts\";\nimport { isFixedDiagnostic, renderDiagnostic } from \"./dialects/diagnostics.ts\";\nimport type { DiagnosticStatement } from \"./dialects/diagnostics.ts\";\nimport { renderPostgresExplain, renderPostgresWorkload } from \"./dialects/postgres-diagnostics.ts\";\nimport { renderRlsReadinessQuery, renderRlsProbeTable, renderRlsPolicyPath } from \"./dialects/postgres-rls-readiness.ts\";\n/**\n * Statement renderer: SQL AST × dialect → { text, values, returning }.\n *\n * The shared grammar lives here; every dialect divergence goes through an\n * explicit SqlDialect strategy field. Malformed ASTs throw VIBE_INTERNAL —\n * the AST is built by VibeORM code, so a bad shape is always our bug.\n */\n\nimport { assertSqlNamespace, internalError, unsupportedCapability } from \"@vibeorm/schema\";\nimport { isSqlFragment, renderSqlFragment, sqlUsesIncoming } from \"./composable.ts\";\nimport type { SqlFragmentSpec } from \"@vibeorm/schema\";\nimport type { ColRef, JsonParamCell, KeyTableJoin, KeyTableMember, OrderTerm, SqlStatement, RlsReadinessStatement, RlsProbeTableStatement, RlsPolicyPathStatement, SqlExpr, TableRef } from \"./ast.ts\";\nimport type {\n AggFn,\n AggRef,\n ChainResult,\n ChainRowSource,\n ChainStatement,\n ChainStepStatement,\n DeleteStatement,\n InsertSelectStatement,\n InsertStatement,\n KeyListMember,\n KeyPage,\n KeyRows,\n OrderByColumn,\n LateralJoin,\n LeftJoin,\n CountSubquery,\n ReturningColumn,\n SelectExpr,\n SelectStatement,\n SetOperator,\n UpdateStatement,\n} from \"./ast.ts\";\nimport { CHAIN_VETO_PREFIX, CHAIN_VETO_TOKEN_PATTERN, isDbNowMarker, isExcludedRef, isJsonParamCell, isListSetOperation, isSetOperation, isSqlDefaultCell, isSqlKeepCell, isStepColumnRef } from \"./ast.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { containsPattern, endsWithPattern, startsWithPattern, strictMatchCollationPrefilter, strictMatchPattern } from \"./like.ts\";\nimport { renderAdvisoryLock, renderRowLockClause } from \"./locks.ts\";\nimport { ParamCollector } from \"./params.ts\";\nimport { isJsonListParameter, jsonListParameter } from \"./json-list-parameter.ts\";\nimport { keyListBindsUntypedRows, postgresBulkInsertArrayCast, postgresKeyListElementType } from \"./key-list.ts\";\nimport { renderRlsContext, renderRlsDisable, renderRlsDropPolicy, renderRlsEnable, renderRlsForce, renderRlsNoForce, renderRlsPolicy, renderRlsRole } from \"./dialects/postgres-rls.ts\";\n\n// ─── Result shape ─────────────────────────────────────────────────\n\nexport type RenderedQuery = {\n readonly text: string;\n readonly values: unknown[];\n /**\n * RETURNING status: \"native\" (rendered), \"omitted\" (requested but the dialect\n * lacks it — caller must re-select), \"none\" (not requested).\n */\n readonly returning: \"native\" | \"omitted\" | \"none\";\n};\n\n// ─── Entry point ──────────────────────────────────────────────────\n\nexport function renderStatement(params: { dialect: SqlDialect; statement: DiagnosticStatement | SqlStatement | RlsReadinessStatement | RlsProbeTableStatement | RlsPolicyPathStatement }): RenderedQuery {\n const { dialect, statement } = params;\n const collector = new ParamCollector(dialect);\n switch (statement.kind) {\n case \"diagnostic\": {\n // EPIC 5: `postgresExplain` wraps another statement, so it renders that\n // one first and keeps its parameters; the read-only workload reads take\n // their own identifiers and bounds. Everything else is a fixed probe.\n if (isFixedDiagnostic(statement)) return renderDiagnostic({ dialect, query: statement.query });\n if (statement.query === \"postgresExplain\") {\n return renderPostgresExplain({\n dialect,\n query: renderStatement({ dialect, statement: statement.statement }),\n ...(statement.options === undefined ? {} : { options: statement.options }),\n });\n }\n return renderPostgresWorkload({ dialect, ...statement });\n }\n case \"select\":\n return renderSelect({ dialect, statement, collector });\n case \"advisoryLock\":\n return renderAdvisoryLock({ dialect, statement, collector });\n case \"insert\":\n return renderInsert({ dialect, statement, collector });\n case \"update\":\n return renderUpdate({ dialect, statement, collector });\n case \"delete\":\n return renderDelete({ dialect, statement, collector });\n case \"chain\":\n return renderChain({ dialect, statement, collector });\n case \"rlsReadiness\": return renderRlsReadinessQuery({ dialect, ...statement });\n case \"rlsProbeTable\": return renderRlsProbeTable({ dialect, ...statement });\n case \"rlsPolicyPath\": return renderRlsPolicyPath({ dialect, ...statement });\n case \"rlsEnable\":\n return renderRlsEnable({ dialect, table: statement.table });\n case \"rlsForce\":\n return renderRlsForce({ dialect, table: statement.table });\n case \"rlsDisable\":\n return renderRlsDisable({ dialect, table: statement.table });\n case \"rlsNoForce\":\n return renderRlsNoForce({ dialect, table: statement.table });\n case \"rlsDropPolicy\":\n return renderRlsDropPolicy({ dialect, table: statement.table, policyName: statement.policyName });\n case \"rlsPolicy\":\n return renderRlsPolicy({ dialect, ...statement });\n case \"rlsContext\":\n return renderRlsContext({ dialect, ...statement });\n case \"rlsRole\":\n return renderRlsRole({ dialect, role: statement.role });\n }\n}\n\n// ─── Shared pieces ────────────────────────────────────────────────\n\nfunction quoteCol(dialect: SqlDialect, column: ColRef): string {\n const name = dialect.quoteIdent({ name: column.name });\n const ref = column.table === undefined ? name : `${dialect.quoteIdent({ name: column.table })}.${name}`;\n // B4: sqlite Decimal compare/order/aggregate sites read the TEXT column as\n // REAL — the builder sets this only there, never on projections.\n if (column.castReal === true) {\n if (dialect.name !== \"sqlite\") {\n throw internalError({ message: \"ColRef.castReal is a sqlite Decimal construct\" });\n }\n return `CAST(${ref} AS REAL)`;\n }\n // D3: postgres `json` order/distinct/compare sites read the column as jsonb.\n if (column.castJsonb !== undefined) {\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: \"ColRef.castJsonb is a postgres json construct\" });\n }\n return `${ref}::${column.castJsonb}`;\n }\n return ref;\n}\n\n/**\n * An ORDER BY / DISTINCT ON column of a SELECT, protected from binding to an\n * OUTPUT column. Postgres, MySQL and SQLite all resolve a bare name in ORDER\n * BY (postgres: DISTINCT ON too) to an output column of that name FIRST. When\n * the projection renames something else to the column's name — a postgres\n * `Float[]`/`Json[]` list read as `\"col\"::text AS \"col\"`, or a projection\n * alias — the bare name would order the TEXT, not the typed column\n * (`{10}` < `{1e-07}` < `{9}`). Such a reference is qualified with the\n * select's FROM name (its alias, or the derived-table name), which only ever\n * names the input column. Qualified references, casts (`castReal`,\n * `castJsonb` — expressions read input columns) and plain projections render\n * unchanged. Window ORDER BY (ROW_NUMBER) never sees output names, so it is\n * not passed through here.\n */\nfunction typedOrderRef(params: { statement: SelectStatement; column: ColRef }): ColRef {\n const { statement, column } = params;\n if (column.table !== undefined || column.castReal === true || column.castJsonb !== undefined) return column;\n const renamed = statement.columns.some(\n (projected) => (projected.alias ?? projected.name) === column.name && (projected.transform !== undefined || projected.alias !== undefined),\n );\n return renamed ? { ...column, table: statement.table.alias ?? statement.table.name } : column;\n}\n\n/**\n * The cast a {@link JsonParamCell} renders after its placeholder: the\n * dialect's json param cast (`::text::jsonb` on postgres, empty elsewhere),\n * or `::text::json` for a cell bound for a postgres `json` column — the\n * server parses the text as `json` and stores it as written (D3).\n */\nfunction jsonCellCast(dialect: SqlDialect, cell: JsonParamCell): string {\n if (cell.storage !== \"json\" || dialect.jsonParamCast === \"\") return dialect.jsonParamCast;\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: \"JsonParamCell storage json is a postgres construct\" });\n }\n return \"::text::json\";\n}\n\n/**\n * Projection rendering: a plain reference or its wire transform. JSON text\n * projections use the dialect primitive and keep explicit aliases. Text casts\n * preserve lossless transport on every dialect; both base64 forms remain\n * postgres-only.\n */\nfunction quoteProjection(dialect: SqlDialect, column: ColRef): string {\n if (column.transform === undefined) {\n const base = quoteCol(dialect, column);\n if (column.alias === undefined) return base;\n return `${base} AS ${dialect.quoteIdent({ name: column.alias })}`;\n }\n if (column.transform === \"jsonText\") {\n const ref = quoteCol(dialect, column);\n const alias = dialect.quoteIdent({ name: column.alias ?? column.name });\n return `${dialect.jsonTextProjection({ expression: ref })} AS ${alias}`;\n }\n const ref = quoteCol(dialect, column);\n const alias = dialect.quoteIdent({ name: column.alias ?? column.name });\n if (column.transform === \"castText\") return `${textProjection({ dialect, expression: ref })} AS ${alias}`;\n // Lane J: MySQL's lateral subselect ships Bytes as `TO_BASE64` (a newline\n // every 76 characters, which the base64 decoder skips).\n if (column.transform === \"encodeBase64\" && dialect.name === \"mysql\") return `TO_BASE64(${ref}) AS ${alias}`;\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: `${column.transform} is a postgres construct` });\n }\n if (column.transform === \"encodeArrayBase64\") return `encode(array_send(${ref}), 'base64') AS ${alias}`;\n return `encode(${ref}, 'base64') AS ${alias}`;\n}\n\nfunction textProjection(params: { dialect: SqlDialect; expression: string }): string {\n return params.dialect.name === \"postgres\" ? `${params.expression}::text`\n : `CAST(${params.expression} AS ${params.dialect.name === \"mysql\" ? \"CHAR\" : \"TEXT\"})`;\n}\n\n/**\n * A SELECT list rendered exactly as a {@link SelectStatement}'s columns are —\n * plain references and their wire transforms (`\"t\".\"scores\"::text AS\n * \"scores\"`) — for SQL assembled outside the AST (extension statements), so\n * its rows reach the driver in the same formats as `findMany`'s.\n */\nexport function renderProjection(params: { dialect: SqlDialect; columns: readonly ColRef[] }): string {\n const { dialect, columns } = params;\n return columns.map((column) => quoteProjection(dialect, column)).join(\", \");\n}\n\nfunction renderTable(dialect: SqlDialect, table: TableRef): string {\n if (table.namespace !== undefined) assertSqlNamespace({ namespace: table.namespace, dialect: dialect.name });\n const relation = dialect.quoteIdent({ name: table.name });\n const name = table.namespace === undefined ? relation : `${dialect.quoteIdent({ name: table.namespace })}.${relation}`;\n if (table.alias === undefined) return name;\n return `${name} AS ${dialect.quoteIdent({ name: table.alias })}`;\n}\n\nfunction assertCount(value: number, what: string): void {\n if (!Number.isSafeInteger(value) || value < 0) {\n throw internalError({ message: `${what} must be a non-negative integer, got ${value}` });\n }\n}\n\nconst COMPARISON_SQL: Readonly<Record<string, string>> = {\n eq: \"=\",\n ne: \"<>\",\n gt: \">\",\n gte: \">=\",\n lt: \"<\",\n lte: \"<=\",\n};\n\n/**\n * Atomic SET arithmetic. `divide` is plain `/`: integer columns therefore\n * follow each dialect's own integer-division rule (pg/sqlite truncate, mysql\n * promotes to decimal) — pinned by the update-atomic-ops catalog case.\n */\nconst SET_OPERATION_SQL: Readonly<Record<SetOperator, string>> = {\n increment: \"+\",\n decrement: \"-\",\n multiply: \"*\",\n divide: \"/\",\n};\n\nconst AGG_FN_SQL: Readonly<Record<AggFn, string>> = {\n count: \"COUNT\",\n avg: \"AVG\",\n sum: \"SUM\",\n min: \"MIN\",\n max: \"MAX\",\n};\n\n/** `COUNT(*)` / `FN(\"col\")` — shared by projections, HAVING and ORDER BY. */\nfunction renderAggRef(dialect: SqlDialect, agg: AggRef): string {\n if (agg.fn === \"countAll\") return \"COUNT(*)\";\n return `${AGG_FN_SQL[agg.fn]}(${quoteCol(dialect, agg.column)})`;\n}\n\nfunction assertScalarArrays(dialect: SqlDialect, feature: string): void {\n if (dialect.capabilities.scalarArrays) return;\n throw unsupportedCapability({\n dialect: dialect.name,\n feature,\n hint: \"only postgres has native array columns — model the list as a related table instead\",\n });\n}\n\n// ─── Expressions ──────────────────────────────────────────────────\n\n/**\n * Render one boolean expression into SQL text, collecting parameters into the\n * shared collector. Public so extension delegates can AND user `where` trees\n * (compiled by the runtime) into their own statements.\n */\nexport function renderExpr(params: { dialect: SqlDialect; expr: SqlExpr; collector: ParamCollector }): string {\n const { dialect, expr, collector } = params;\n\n switch (expr.kind) {\n case \"cmp\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n // Database-clock operand: the dialect's now() expression, never a param.\n if (isDbNowMarker(expr.value)) {\n return `${quoteCol(dialect, expr.column)} ${op} ${dialect.renderDbNow({ offsetSeconds: expr.value.offsetSeconds, collector })}`;\n }\n const compared = listComparison({ dialect, column: expr.column, value: expr.value, collector });\n return `${compared.column} ${op} ${compared.operand}`;\n }\n\n case \"cmpCol\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n return `${quoteCol(dialect, expr.left)} ${op} ${quoteCol(dialect, expr.right)}`;\n }\n\n case \"isNull\":\n return `${quoteCol(dialect, expr.column)} IS ${expr.negate === true ? \"NOT NULL\" : \"NULL\"}`;\n\n case \"inArray\": {\n if (expr.values.length === 0) {\n // Empty IN matches nothing; empty NOT IN matches everything.\n return expr.negate === true ? \"1 = 1\" : \"1 = 0\";\n }\n const column = quoteCol(dialect, expr.column);\n if (expr.timeOfDay === true && dialect.timeOfDayInStrategy === \"equalities\") {\n const equalities = collector.addMany(expr.values).map((placeholder) => `${column} = ${placeholder}`);\n return `${expr.negate === true ? \"NOT \" : \"\"}(${equalities.join(\" OR \")})`;\n }\n if (dialect.inArrayStrategy === \"any\") {\n const base = `${column} = ANY(${collector.add(Array.isArray(expr.values) ? [...expr.values] : expr.values)})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n const placeholders = collector.addMany(expr.values);\n return `${column} ${expr.negate === true ? \"NOT IN\" : \"IN\"} (${placeholders.join(\", \")})`;\n }\n\n case \"tupleIn\": {\n if (expr.columns.length === 0) {\n throw internalError({ message: \"tupleIn needs at least one column\" });\n }\n for (const row of expr.rows) {\n if (row.length !== expr.columns.length) {\n throw internalError({\n message: `tupleIn row has ${row.length} values for ${expr.columns.length} columns`,\n });\n }\n }\n if (expr.rows.length === 0) {\n // Same honesty as inArray: an empty membership matches nothing.\n return expr.negate === true ? \"1 = 1\" : \"1 = 0\";\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n if (dialect.tupleInStrategy === \"rowValue\") {\n const tuples = expr.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n const base = `(${columns.join(\", \")}) IN (${tuples.join(\", \")})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n // No row constructors: an OR of COMPLETE conjunctions, never a per-column\n // IN (which would match the Cartesian product of the members).\n const conjunctions = expr.rows.map((row) => {\n const terms = row.map((value, index) => `${columns[index] as string} = ${collector.add(value)}`);\n return terms.length === 1 ? (terms[0] as string) : `(${terms.join(\" AND \")})`;\n });\n const base = conjunctions.length === 1 ? (conjunctions[0] as string) : `(${conjunctions.join(\" OR \")})`;\n return expr.negate === true ? `NOT ${base.startsWith(\"(\") ? base : `(${base})`}` : base;\n }\n\n case \"keyList\":\n return renderKeyList({ dialect, expr, collector });\n\n case \"rowCompare\": {\n // D-01: one row-value comparison; values bind in member order.\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined || expr.columns.length === 0 || expr.values.length !== expr.columns.length) {\n throw internalError({ message: `rowCompare needs a range operator and one value per column (${expr.columns.length} columns, ${expr.values.length} values)` });\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const placeholders = expr.values.map((value) => collector.add(value));\n return `(${columns.join(\", \")}) ${op} (${placeholders.join(\", \")})`;\n }\n\n case \"inSelect\": {\n // D-04: the subquery shares the collector, like EXISTS.\n if (expr.columns.length === 0) throw internalError({ message: \"inSelect needs at least one column\" });\n if (dialect.name === \"mysql\" && (expr.select.limit !== undefined || expr.select.offset !== undefined)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"LIMIT inside an IN subquery\",\n hint: \"mysql refuses LIMIT directly inside an IN subquery (error 1235); wrap the limited select in a derived table\",\n });\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const tested = columns.length === 1 ? (columns[0] as string) : `(${columns.join(\", \")})`;\n const sub = renderSelect({ dialect, statement: expr.select, collector });\n return `${tested} IN (${sub.text})`;\n }\n\n case \"like\": {\n const column = quoteCol(dialect, expr.column);\n const placeholder = collector.add(expr.pattern);\n let base: string;\n if (expr.insensitive === true) {\n base =\n dialect.insensitiveLike === \"ilike\"\n ? `${column} ILIKE ${placeholder}`\n : expr.ciCollation === true\n ? // #36: the column's declared `_ci` collation already folds case —\n // plain LIKE keeps the index usable.\n `${column} LIKE ${placeholder}`\n : `LOWER(${column}) LIKE LOWER(${placeholder})`;\n } else {\n base = `${column} LIKE ${placeholder}`;\n }\n if (dialect.likeEscapeClause !== null) {\n base = `${base}${dialect.likeEscapeClause}`;\n }\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"strictMatch\": {\n const column = quoteCol(dialect, expr.column);\n let base: string;\n if (expr.op === \"equals\") {\n // pg and sqlite `=` are already byte-exact; only mysql's `_ci`\n // collations fold equality and need the BINARY cast.\n base =\n dialect.strictMatchStrategy === \"binary\"\n ? `${column} = CAST(${collector.add(expr.value)} AS BINARY)`\n : `${column} = ${collector.add(expr.value)}`;\n } else {\n const pattern = strictMatchPattern({\n strategy: dialect.strictMatchStrategy,\n op: expr.op,\n value: expr.value,\n });\n if (dialect.strictMatchStrategy === \"glob\") {\n base = `${column} GLOB ${collector.add(pattern)}`;\n } else {\n // Fix lane Q2 (D-06): mysql strict startsWith ANDs the collation\n // LIKE first (same pattern, bound first) — an index-boundable\n // superset of the byte-exact test, so the rows are unchanged.\n const prefilter = strictMatchCollationPrefilter({\n strategy: dialect.strictMatchStrategy,\n op: expr.op,\n negate: expr.negate === true,\n })\n ? `${column} LIKE ${collector.add(pattern)}${dialect.likeEscapeClause ?? \"\"}`\n : null;\n const placeholder = collector.add(pattern);\n base =\n dialect.strictMatchStrategy === \"binary\"\n ? `${column} LIKE CAST(${placeholder} AS BINARY)`\n : `${column} LIKE ${placeholder}`;\n if (dialect.likeEscapeClause !== null) base = `${base}${dialect.likeEscapeClause}`;\n if (prefilter !== null) base = `(${prefilter} AND ${base})`;\n }\n }\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"and\":\n case \"or\": {\n if (expr.operands.length === 0) {\n // Neutral elements: empty AND is always-true, empty OR always-false.\n return expr.kind === \"and\" ? \"1 = 1\" : \"1 = 0\";\n }\n if (expr.operands.length === 1) {\n return renderExpr({ dialect, expr: expr.operands[0]!, collector });\n }\n const joiner = expr.kind === \"and\" ? \" AND \" : \" OR \";\n const rendered = expr.operands.map((operand) => renderExpr({ dialect, expr: operand, collector }));\n return `(${rendered.join(joiner)})`;\n }\n\n case \"not\":\n return `NOT (${renderExpr({ dialect, expr: expr.operand, collector })})`;\n\n case \"aggCmp\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n return `${renderAggRef(dialect, expr.agg)} ${op} ${collector.add(expr.value)}`;\n }\n\n case \"arrayHas\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"has\\\"\");\n const compared = listComparison({ dialect, column: expr.column, value: expr.value, collector });\n const base = `${compared.operand} = ANY(${compared.column})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"arrayContainsAll\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"hasEvery\\\"\");\n const values = Array.isArray(expr.values) ? [...expr.values] : expr.values;\n const compared = listComparison({ dialect, column: expr.column, value: values, collector });\n return `${compared.column} @> ${compared.operand}`;\n }\n\n case \"arrayOverlaps\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"hasSome\\\"\");\n const values = Array.isArray(expr.values) ? [...expr.values] : expr.values;\n const compared = listComparison({ dialect, column: expr.column, value: values, collector });\n return `${compared.column} && ${compared.operand}`;\n }\n\n case \"arrayIsEmpty\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"isEmpty\\\"\");\n // v1 semantics kept: array_length of NULL and of '{}' are both NULL, so\n // `isEmpty: true` matches NULL **and** empty lists.\n const column = quoteCol(dialect, expr.column);\n return `array_length(${column}, 1) IS ${expr.empty ? \"NULL\" : \"NOT NULL\"}`;\n }\n\n case \"jsonFilter\":\n return renderJsonFilter({ dialect, expr, collector });\n\n case \"exists\": {\n // The subquery shares the statement's collector, so its parameters land\n // in the single sequence exactly where they appear in the text.\n const sub = renderSelect({ dialect, statement: expr.select, collector });\n return `${expr.negate === true ? \"NOT \" : \"\"}EXISTS (${sub.text})`;\n }\n\n case \"composed\":\n return `(${renderSqlFragment({ dialect, fragment: expr.fragment, collector })})`;\n\n case \"fragment\":\n return renderFragment({ dialect, fragment: expr.fragment, collector });\n\n case \"raw\":\n return expr.text;\n }\n}\n\n// ─── Bound fragments (extension SQL plane) ───────────────────\n\n/**\n * Render a neutral bound fragment (extensions.md §3): literal text verbatim,\n * `{ param }` through the collector (single placeholder sequence), `{ ident }`\n * paths through dialect.quoteIdent. Exported so extension delegates can build\n * full statements sharing one collector with core-compiled WHERE trees.\n */\nexport function renderFragment(params: {\n dialect: SqlDialect;\n fragment: SqlFragmentSpec;\n collector: ParamCollector;\n}): string {\n const { dialect, fragment, collector } = params;\n let text = \"\";\n for (const part of fragment.parts) {\n if (typeof part === \"string\") {\n text += part;\n } else if (\"param\" in part) {\n text += collector.add(part.param);\n } else {\n text += part.ident.map((name) => dialect.quoteIdent({ name })).join(\".\");\n }\n }\n return text;\n}\n\n// ─── JSON path filters ─────────────────────────────────────────────\n\n/** `$.a.b[0]` path string for sqlite/mysql — always bound, never spliced. */\nfunction jsonPathString(path: readonly (string | number)[]): string {\n let out = \"$\";\n for (const segment of path) {\n if (typeof segment === \"number\") {\n out += `[${segment}]`;\n } else if (/^[A-Za-z_][A-Za-z0-9_]*$/.test(segment)) {\n out += `.${segment}`;\n } else {\n // A quoted key uses JSON-string escaping in both engines' path syntax:\n // the backslash FIRST, or a key containing one silently matches nothing.\n out += `.\"${segment.replaceAll(\"\\\\\", \"\\\\\\\\\").replaceAll('\"', '\\\\\"')}\"`;\n }\n }\n return out;\n}\n\n/**\n * Column and operand of a comparison (`cmp`, `has`, `hasEvery`, `hasSome`).\n * A Json-list operand of a `json[]` column (`Json[] @db.Json`) compares as\n * jsonb on both sides — `\"col\"::jsonb[]` against `$n::text::jsonb[]` (or\n * `$n::text::jsonb` for one element) — because `json` has no equality\n * operator at all (\"could not identify an equality operator for type json\").\n * Write sites (`push`) keep the `json` operand. Everything else renders as\n * before. The column side is added first only in text: it binds nothing.\n */\nfunction listComparison(params: {\n dialect: SqlDialect;\n column: ColRef;\n value: unknown;\n collector: ParamCollector;\n}): { readonly column: string; readonly operand: string } {\n const { dialect, column, value, collector } = params;\n if (isJsonListParameter(value) && value.storage === \"json\") {\n return {\n column: `${quoteCol(dialect, column)}::jsonb[]`,\n operand: collector.add(jsonListParameter({ value: value.value, storage: \"jsonb\" })),\n };\n }\n return { column: quoteCol(dialect, column), operand: collector.add(value) };\n}\n\ntype KeyListExpr = Extract<SqlExpr, { kind: \"keyList\" }>;\n\n/**\n * Key-list membership per `SqlDialect.keyListStrategy` (see the `keyList`\n * node): postgres binds one typed array per member and unnests them in a\n * semi-join subquery — except when a member is a `DateTime` without a\n * declared native type ({@link keyListBindsUntypedRows}): then it renders the\n * row-constructor list of untyped parameters, so each member is typed from\n * its column like `\"col\" = $n`; mysql renders the row-constructor list (an OR\n * of complete conjunctions when a member is a time of day and the dialect\n * declares `equalities` for it); sqlite renders `IN (VALUES …)`.\n */\nfunction renderKeyList(params: { dialect: SqlDialect; expr: KeyListExpr; collector: ParamCollector }): string {\n const { dialect, expr, collector } = params;\n const arity = expr.columns.length;\n if (arity === 0) throw internalError({ message: \"keyList needs at least one column\" });\n if (expr.members.length !== arity) {\n throw internalError({ message: `keyList has ${expr.members.length} members for ${arity} columns` });\n }\n for (const row of expr.rows) {\n if (row.length !== arity) throw internalError({ message: `keyList row has ${row.length} values for ${arity} columns` });\n }\n // Same honesty as inArray: an empty key list matches nothing.\n if (expr.rows.length === 0) return \"1 = 0\";\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const tuple = arity === 1 ? (columns[0] as string) : `(${columns.join(\", \")})`;\n if (dialect.keyListStrategy === \"unnest\") {\n // Every member's element type first: a member without one (Json, an\n // unknown native type) is refused in either form.\n const types = expr.members.map((member) => postgresKeyListElementType({ dialect, member }));\n if (!keyListBindsUntypedRows({ members: expr.members })) {\n const arrays = types.map((type, index) => `${collector.add(expr.rows.map((row) => row[index]))}::${type}[]`);\n return `${tuple} IN (SELECT * FROM unnest(${arrays.join(\", \")}))`;\n }\n }\n if (dialect.timeOfDayInStrategy === \"equalities\" && expr.members.some((member) => member.timeOfDay === true)) {\n const conjunctions = expr.rows.map((row) => {\n const terms = row.map((value, index) => `${columns[index] as string} = ${collector.add(value)}`);\n return terms.length === 1 ? (terms[0] as string) : `(${terms.join(\" AND \")})`;\n });\n return conjunctions.length === 1 ? (conjunctions[0] as string) : `(${conjunctions.join(\" OR \")})`;\n }\n const tuples = expr.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n return dialect.keyListStrategy === \"values\"\n ? `${tuple} IN (VALUES ${tuples.join(\", \")})`\n : `${tuple} IN (${tuples.join(\", \")})`;\n}\n\n// ─── Fix lane Q1 (round 3, DB-01): per-key page ─────────────────────────\n\n/** Key-list source alias of a per-key page; its members are `__vibe_k<i>` on postgres. */\nconst KEY_PAGE_KEYS = \"__vibe_keys\";\n/** Postgres: the lateral page of identity keys. */\nconst KEY_PAGE_IDS = \"__vibe_ids\";\n/** The child table re-read by identity. */\nconst KEY_PAGE_ROWS = \"__vibe_page\";\n\n/** Members of a {@link KeyPage}'s `select` the per-key page renders; any other is a malformed node. */\nconst KEY_PAGE_SELECT_MEMBERS: ReadonlySet<string> = new Set([\"kind\", \"table\", \"columns\", \"where\", \"orderBy\", \"limit\", \"offset\"]);\n\n/**\n * The per-key page (`SelectStatement.keyPage`) per `SqlDialect.keyPageStrategy`\n * — see {@link KeyPage}. Parameters join the shared sequence in text order:\n * the key tuples (FROM), then the page's own `where`.\n */\nfunction renderKeyPage(params: { dialect: SqlDialect; page: KeyPage; collector: ParamCollector }): string {\n const { dialect, page, collector } = params;\n const { select } = page;\n const arity = page.keyColumns.length;\n if (arity === 0 || page.members.length !== arity) {\n throw internalError({ message: `keyPage has ${page.members.length} members for ${arity} key columns` });\n }\n if (page.rows.length === 0) throw internalError({ message: \"keyPage needs at least one key\" });\n for (const row of page.rows) {\n if (row.length !== arity) throw internalError({ message: `keyPage row has ${row.length} values for ${arity} key columns` });\n }\n if (page.identity.length === 0) throw internalError({ message: \"keyPage needs the child's identity columns\" });\n const order = select.orderBy ?? [];\n if (order.length === 0 || order.some((term) => !(\"column\" in term))) {\n throw internalError({ message: \"keyPage needs a non-empty order of plain column terms\" });\n }\n if (select.table.alias !== undefined || Object.keys(select).some((member) => !KEY_PAGE_SELECT_MEMBERS.has(member))) {\n throw internalError({ message: \"keyPage select carries a member the per-key page cannot render\" });\n }\n if (dialect.keyPageStrategy === \"window\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a per-key page (keyPage)\",\n hint: \"the runtime keeps the ROW_NUMBER window on this dialect\",\n });\n }\n const pageRef = (column: ColRef): ColRef => ({ ...column, table: KEY_PAGE_ROWS });\n const projection = select.columns.map((column) => quoteProjection(dialect, pageRef(column)));\n const withKey = (keyRef: (index: number) => ColRef): SqlExpr => {\n const equalities: SqlExpr[] = page.keyColumns.map((column, index) => ({ kind: \"cmpCol\", op: \"eq\", left: column, right: keyRef(index) }));\n const operands = select.where === undefined ? equalities : [...equalities, select.where];\n return operands.length === 1 ? (operands[0] as SqlExpr) : { kind: \"and\", operands };\n };\n const keyPage = (where: SqlExpr, rank: boolean): SelectStatement => ({\n kind: \"select\",\n table: select.table,\n columns: page.identity,\n ...(rank ? { rowNumber: { partitionBy: page.keyColumns, orderBy: order, alias: page.rankAlias } } : {}),\n where,\n orderBy: order,\n ...(select.limit === undefined ? {} : { limit: select.limit }),\n ...(select.offset === undefined ? {} : { offset: select.offset }),\n });\n const rows = renderTable(dialect, { ...select.table, alias: KEY_PAGE_ROWS });\n const keyAlias = select.table.name === KEY_PAGE_KEYS ? `${KEY_PAGE_KEYS}_1` : KEY_PAGE_KEYS;\n const keys = dialect.quoteIdent({ name: keyAlias });\n\n if (dialect.keyPageStrategy === \"lateral\") {\n // One typed array per member, exactly the key-list filter's element types.\n if (keyListBindsUntypedRows({ members: page.members })) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a per-key page over a DateTime key without a declared native type\",\n hint: \"the runtime keeps the ROW_NUMBER window for such keys\",\n });\n }\n const types = page.members.map((member) => postgresKeyListElementType({ dialect, member }));\n const arrays = types.map((type, index) => `${collector.add(page.rows.map((row) => row[index]))}::${type}[]`);\n const names = page.keyColumns.map((_, index) => dialect.quoteIdent({ name: `__vibe_k${index}` }));\n const ids = renderSelect({ dialect, statement: keyPage(withKey((index) => ({ table: keyAlias, name: `__vibe_k${index}` })), true), collector });\n const on = page.identity.map((column) => `${quoteCol(dialect, pageRef(column))} = ${quoteCol(dialect, { table: KEY_PAGE_IDS, name: column.name })}`).join(\" AND \");\n const rank = quoteCol(dialect, { table: KEY_PAGE_IDS, name: page.rankAlias });\n return `SELECT ${[...projection, rank].join(\", \")} FROM unnest(${arrays.join(\", \")}) AS ${keys} (${names.join(\", \")}) CROSS JOIN LATERAL (${ids.text}) AS ${dialect.quoteIdent({ name: KEY_PAGE_IDS })} INNER JOIN ${rows} ON ${on}`;\n }\n\n // inLimit: the rank is re-derived over the fetched page — rendered first,\n // it is text order; plain column terms bind nothing.\n const partition = page.keyColumns.map((column) => quoteCol(dialect, pageRef(column))).join(\", \");\n const rankOrder = order.map((term) => renderOrderTerm({ dialect, term: { ...term, column: pageRef((term as OrderByColumn).column) }, collector })).join(\", \");\n const rank = `ROW_NUMBER() OVER (PARTITION BY ${partition} ORDER BY ${rankOrder}) AS ${dialect.quoteIdent({ name: page.rankAlias })}`;\n const tuples = page.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n // SQLite names a VALUES clause's columns column1, column2, … (documented).\n const membership = renderExpr({\n dialect,\n expr: { kind: \"inSelect\", columns: page.identity.map(pageRef), select: keyPage(withKey((index) => ({ table: keyAlias, name: `column${index + 1}` })), false) },\n collector,\n });\n return `SELECT ${[...projection, rank].join(\", \")} FROM (VALUES ${tuples.join(\", \")}) AS ${keys} INNER JOIN ${rows} ON ${membership}`;\n}\n\n// ─── Statement-count pass EPIC 4 (ST-07): key rows ───\n\n/**\n * The derived table of `SelectStatement.fromKeys` (see {@link KeyRows}):\n * `unnest($1::<type>[], …) AS \"<name>\" (\"<column>\", …)` — one typed array per\n * column, bound at the FROM position of the shared parameter sequence.\n *\n * @throws VibeError `VIBE_UNSUPPORTED_CAPABILITY` on a dialect without the\n * typed-array key list (`keyListStrategy` other than `unnest`), for a\n * `DateTime` member without a declared native type, and for a member type\n * the key list does not know.\n */\nfunction renderKeyRows(params: { dialect: SqlDialect; statement: SelectStatement; keys: KeyRows; collector: ParamCollector }): string {\n const { dialect, statement, keys, collector } = params;\n if (statement.fromSelect !== undefined || statement.keyPage !== undefined || statement.fromUnion !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"fromKeys uses table.name as the derived-table alias — fromSelect, keyPage, fromUnion and table.alias must be unset\" });\n }\n // A lock over bound key rows would lock nothing.\n if (statement.rowLock !== undefined) throw internalError({ message: \"a locking read cannot read from key rows\" });\n const arity = keys.columns.length;\n if (arity === 0 || keys.members.length !== arity) {\n throw internalError({ message: `fromKeys has ${keys.members.length} members for ${arity} columns` });\n }\n if (keys.rows.length === 0) throw internalError({ message: \"fromKeys needs at least one key row\" });\n for (const row of keys.rows) {\n if (row.length !== arity) throw internalError({ message: `fromKeys row has ${row.length} values for ${arity} columns` });\n }\n if (dialect.keyListStrategy !== \"unnest\" || keyListBindsUntypedRows({ members: keys.members })) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: dialect.keyListStrategy !== \"unnest\" ? \"a key-rows FROM (fromKeys)\" : \"a key-rows FROM over a DateTime key without a declared native type\",\n hint: \"the runtime keeps the per-relation loads for this write\",\n });\n }\n const types = keys.members.map((member) => postgresKeyListElementType({ dialect, member }));\n const arrays = types.map((type, index) => `${collector.add(keys.rows.map((row) => row[index]))}::${type}[]`);\n const names = keys.columns.map((name) => dialect.quoteIdent({ name }));\n return `unnest(${arrays.join(\", \")}) AS ${dialect.quoteIdent({ name: statement.table.name })} (${names.join(\", \")})`;\n}\n\n// ─── Fix lane Q2 (round 3, DB-07): union page ───\n\n/** Members a {@link SelectStatement.fromUnion} branch may carry; any other is a malformed node. */\nconst UNION_BRANCH_MEMBERS: ReadonlySet<string> = new Set([\"kind\", \"table\", \"columns\", \"where\", \"orderBy\", \"limit\"]);\n\n/**\n * The `UNION ALL` of a union page (`SelectStatement.fromUnion`), each branch\n * in its own derived table `\"__vibe_u<i>\"` — see the field's docs. Branches\n * render (and bind) in order.\n */\nfunction renderUnionPage(params: { dialect: SqlDialect; statement: SelectStatement; collector: ParamCollector }): string {\n const { dialect, statement, collector } = params;\n const branches = statement.fromUnion ?? [];\n if (branches.length < 2) throw internalError({ message: \"fromUnion needs at least two branches\" });\n if (statement.fromSelect !== undefined || statement.keyPage !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"fromUnion uses table.name as the derived-table alias — fromSelect, keyPage and table.alias must be unset\" });\n }\n // A lock over a derived union would not lock the base rows the branches read.\n if (statement.rowLock !== undefined) throw internalError({ message: \"a locking read cannot read from a union page\" });\n const outputNames = (branch: SelectStatement): string => branch.columns.map((column) => column.alias ?? column.name).join(\"\\u0000\");\n const names = outputNames(branches[0] as SelectStatement);\n return branches\n .map((branch, index) => {\n if (branch.columns.length === 0 || Object.keys(branch).some((member) => !UNION_BRANCH_MEMBERS.has(member))) {\n throw internalError({ message: \"a fromUnion branch must be a plain SELECT <columns> FROM <table> [WHERE] [ORDER BY] [LIMIT]\" });\n }\n if (outputNames(branch) !== names) throw internalError({ message: \"fromUnion branches must project the same output names in the same order\" });\n const inner = renderSelect({ dialect, statement: branch, collector });\n return `SELECT * FROM (${inner.text}) AS ${dialect.quoteIdent({ name: `__vibe_u${index}` })}`;\n })\n .join(\" UNION ALL \");\n}\n\ntype JsonFilterExpr = Extract<SqlExpr, { kind: \"jsonFilter\" }>;\n\nfunction jsonStringPattern(params: { expr: JsonFilterExpr }): string {\n const { expr } = params;\n if (typeof expr.value !== \"string\") {\n throw internalError({ message: `json ${expr.op} expects a string operand` });\n }\n if (expr.op === \"string_contains\") return containsPattern({ raw: expr.value });\n if (expr.op === \"string_starts_with\") return startsWithPattern({ raw: expr.value });\n return endsWithPattern({ raw: expr.value });\n}\n\n/** Case-[in]sensitive LIKE over an extracted-text expression, per dialect. */\nfunction renderJsonLike(params: {\n dialect: SqlDialect;\n target: string;\n expr: JsonFilterExpr;\n collector: ParamCollector;\n}): string {\n const { dialect, target, expr, collector } = params;\n const placeholder = collector.add(jsonStringPattern({ expr }));\n let base: string;\n if (expr.insensitive === true) {\n base =\n dialect.insensitiveLike === \"ilike\"\n ? `${target} ILIKE ${placeholder}`\n : `LOWER(${target}) LIKE LOWER(${placeholder})`;\n } else {\n base = `${target} LIKE ${placeholder}`;\n }\n if (dialect.likeEscapeClause !== null) base = `${base}${dialect.likeEscapeClause}`;\n return expr.negate === true ? `NOT (${base})` : base;\n}\n\n/**\n * One JSON path predicate, per dialect strategy. The path is BOUND: a `text[]`\n * parameter on postgres (cast so string-literal array forms work too), a\n * `$.a.b` path string elsewhere. Values bind as JSON text for json/jsonb\n * comparisons and as LIKE patterns for the string ops.\n */\nfunction renderJsonFilter(params: {\n dialect: SqlDialect;\n expr: JsonFilterExpr;\n collector: ParamCollector;\n}): string {\n const { dialect, expr, collector } = params;\n if (!dialect.supportedJsonOps.includes(expr.op)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `the json filter \"${expr.op}\"`,\n hint: `this dialect can express: ${dialect.supportedJsonOps.join(\", \")}`,\n });\n }\n const cmp = expr.negate === true ? \"<>\" : \"=\";\n\n if (dialect.jsonPathMode === \"operators\") {\n const column = quoteCol(dialect, expr.column);\n const pathParam = `${collector.add(expr.path.map(String))}::text[]`;\n // A `json` column (`Json @db.Json`) has no `=`, `<>` or `@>` — postgres\n // defines them for jsonb only (SQLSTATE 42883 `json = jsonb`). The\n // value-comparing ops cast the EXTRACTED value, not the column: the\n // result is jsonb equality and containment, a jsonb column's semantics\n // (json navigation also takes the LAST of duplicate keys), and only the\n // sub-value is converted — ~40% faster than casting the whole document\n // on 20,000 4-KB rows (PostgreSQL 18.6). The string ops read the same\n // jsonb value as text (`#>> '{}'`): json's own `#>>` returns the STORED\n // spelling of a non-string value (`1e2`, `[1, 2]`, both duplicate keys)\n // where a jsonb column reads `100`, `[1, 2]` and the last key. For a\n // string value both forms return the same unescaped text.\n const extracted = expr.storage === \"json\" ? `(${column} #> ${pathParam})::jsonb` : `(${column} #> ${pathParam})`;\n switch (expr.op) {\n case \"equals\":\n return `${extracted} ${cmp} ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = expr.storage === \"json\" ? `(${extracted} #>> '{}')` : `(${column} #>> ${pathParam})`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_contains\":\n return `${extracted} @> ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"array_starts_with\":\n return `${extracted} -> 0 = ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"array_ends_with\":\n return `${extracted} -> -1 = ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n }\n }\n\n if (dialect.jsonPathMode === \"sqliteExtract\") {\n const column = quoteCol(dialect, expr.column);\n // JSON booleans surface as SQL 0/1, so value equality alone loses type.\n const typeMatches = (type: string, value: unknown): string => {\n if (typeof value === \"number\") return `${type} IN ('integer', 'real')`;\n const tag = typeof value === \"boolean\" ? String(value)\n : value === null ? \"null\" : Array.isArray(value) ? \"array\"\n : typeof value === \"object\" ? \"object\" : \"text\";\n return `${type} = '${tag}'`;\n };\n const compareExtracted = (path: string, value: unknown): string => {\n const type = `json_type(${column}, ${collector.add(path)})`;\n const guard = typeMatches(type, value);\n let base = guard;\n if (value !== null) {\n const target = `json_extract(${column}, ${collector.add(path)})`;\n const bound = typeof value === \"boolean\" ? (value ? 1 : 0) : value;\n const comparison = typeof value === \"object\"\n ? renderSqliteJsonEquality({ dialect, left: target, right: collector.add(JSON.stringify(value)) })\n : `${target} = ${collector.add(bound)}`;\n base = `(${guard} AND ${comparison})`;\n }\n return expr.negate === true ? `NOT (${base})` : base;\n };\n switch (expr.op) {\n case \"equals\":\n return compareExtracted(jsonPathString(expr.path), expr.value);\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = `json_extract(${column}, ${collector.add(jsonPathString(expr.path))})`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_starts_with\":\n case \"array_ends_with\": {\n // Edge-element access: `$[0]` / `$[#-1]` path elements (sqlite ≥3.31;\n // bun:sqlite bundles far newer) — N6/board #21.\n const edge = expr.op === \"array_starts_with\" ? \"[0]\" : \"[#-1]\";\n return compareExtracted(`${jsonPathString(expr.path)}${edge}`, expr.value);\n }\n case \"array_contains\": {\n // Scalar-needle containment via json_each() EXISTS — one EXISTS per\n // element, ANDed (jsonb `@>` semantics for scalar members). Deep\n // structural containment (object/array members) has no cheap faithful\n // sqlite form and stays refused; JSON null members compare through\n // json_each's 'null' type tag, not SQL NULL, so they are refused too.\n //\n // Haystack type guard (wave-C review): json_each() over a path holding\n // a SCALAR yields one row carrying that scalar, so an unguarded EXISTS\n // matched `{ tags: \"a\" }` against needle `[\"a\"]` where postgres (`@>`\n // with an array needle) and mysql (JSON_CONTAINS against an array\n // literal) are false. json_type() is NULL for a missing path, so\n // missing paths and NULL columns stay non-matches — and an empty\n // needle reduces to the guard alone: contained in every ARRAY (pg's\n // `@> '[]'` truth) and in nothing else.\n const guard = `json_type(${column}, ${collector.add(jsonPathString(expr.path))}) = 'array'`;\n const elements = Array.isArray(expr.value) ? expr.value : [expr.value];\n const tests = elements.map((element) => {\n if (element === null || (typeof element === \"object\" && element !== null)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"json array_contains with object/array/null elements\",\n hint: \"sqlite expresses scalar-element containment only — deep structural containment needs postgres or mysql\",\n });\n }\n const bound = typeof element === \"boolean\" ? (element ? 1 : 0) : element;\n const path = collector.add(jsonPathString(expr.path));\n const type = `${dialect.quoteIdent({ name: \"json_each\" })}.${dialect.quoteIdent({ name: \"type\" })}`;\n return `EXISTS (SELECT 1 FROM json_each(${column}, ${path}) WHERE ${typeMatches(type, element)} AND ${dialect.quoteIdent({ name: \"json_each\" })}.${dialect.quoteIdent({ name: \"value\" })} = ${collector.add(bound)})`;\n });\n return tests.length === 0 ? guard : `(${[guard, ...tests].join(\" AND \")})`;\n }\n default:\n throw internalError({ message: `json op \"${expr.op}\" leaked past supportedJsonOps on sqlite` });\n }\n }\n\n // mysqlExtract\n const column = quoteCol(dialect, expr.column);\n const pathString = jsonPathString(expr.path);\n switch (expr.op) {\n case \"equals\":\n return `JSON_EXTRACT(${column}, ${collector.add(pathString)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = `JSON_UNQUOTE(JSON_EXTRACT(${column}, ${collector.add(pathString)}))`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_contains\":\n return `JSON_CONTAINS(JSON_EXTRACT(${column}, ${collector.add(pathString)}), CAST(${collector.add(JSON.stringify(expr.value))} AS JSON))`;\n case \"array_starts_with\":\n return `JSON_EXTRACT(${column}, ${collector.add(`${pathString}[0]`)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n case \"array_ends_with\":\n return `JSON_EXTRACT(${column}, ${collector.add(`${pathString}[last]`)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n }\n}\n\n// ─── Ordering ─────────────────────────────────────────────────────\n\nfunction renderOrderTerm(params: { dialect: SqlDialect; term: OrderTerm; collector: ParamCollector }): string {\n const { dialect, term, collector } = params;\n if (\"agg\" in term) {\n return `${renderAggRef(dialect, term.agg)} ${term.direction === \"asc\" ? \"ASC\" : \"DESC\"}`;\n }\n if (\"select\" in term) {\n // Relation orderBy: a correlated scalar subquery — its parameters merge\n // into the shared sequence exactly where they appear in the text.\n const sub = renderSelect({ dialect, statement: term.select, collector });\n return `(${sub.text}) ${term.direction === \"asc\" ? \"ASC\" : \"DESC\"}`;\n }\n const column = quoteCol(dialect, term.column);\n const direction = term.direction === \"asc\" ? \"ASC\" : \"DESC\";\n if (term.nulls === undefined) {\n return `${column} ${direction}`;\n }\n if (dialect.orderByNullsMode === \"native\") {\n return `${column} ${direction} NULLS ${term.nulls === \"first\" ? \"FIRST\" : \"LAST\"}`;\n }\n // Emulation (mysql): the engine's native order already places NULLs FIRST on\n // ASC and LAST on DESC — those pairings render the bare term (the redundant\n // boolean pre-term cost a per-row evaluation and could defeat index-order\n // scans, #14). Only the diverging pairings need the `IS NULL` pre-term:\n // false(0) sorts first, so plain `IS NULL` pushes nulls last and\n // `IS NULL DESC` pulls them first.\n if ((term.nulls === \"first\") === (term.direction === \"asc\")) {\n return `${column} ${direction}`;\n }\n const nullsTerm = term.nulls === \"first\" ? `${column} IS NULL DESC` : `${column} IS NULL`;\n return `${nullsTerm}, ${column} ${direction}`;\n}\n\n// ─── Projections ──────────────────────────────────────────────────\n\nfunction renderSelectExpr(params: { dialect: SqlDialect; expr: SelectExpr }): string {\n const { dialect, expr } = params;\n if (expr.kind === \"one\") return \"1\";\n const alias = expr.alias === undefined ? \"\" : ` AS ${dialect.quoteIdent({ name: expr.alias })}`;\n return `COUNT(*)${alias}`;\n}\n\n// ─── Lateral JSON joins ───────────────────────────────────\n\n/**\n * `LEFT JOIN LATERAL (… to_json …) AS alias ON true`. Postgres SQL, and MySQL\n * 8.0.14+ through `SqlDialect.lateralJson` (lane J: `JSON_ARRAY` rows,\n * `JSON_ARRAYAGG`, an ordered level's `ROW_NUMBER()` position slot) — the\n * runtime gates the \"join\" strategy on `capabilities.lateralJoin` at build\n * time, and this renderer refuses too (dialect honesty, rule 4).\n *\n * `json`, not `jsonb`: the payload is transport — parsed by the driver and\n * never touched by a JSON operator on the server. `jsonb_agg(to_jsonb(…))`\n * builds postgres's binary JSON (sorted, de-duplicated keys) and then\n * serializes it straight back to text for the wire, which measured at 2–3.7×\n * the server time of `json_agg(to_json(…))` for identical decoded values\n * (`.ai/plans/26.09.08 - performance-join-strategy.md` §1.2). The observable\n * differences are textual only: `json` keeps construction key order and `-0`,\n * `jsonb` normalizes both; every scalar still rides the B3 transforms.\n */\nfunction renderPositionalRow(params: { dialect: SqlDialect; join: LateralJoin; subAlias: string }): string {\n const { dialect, join, subAlias } = params;\n const json = lateralJsonOf({ dialect });\n // Lane J: a `positionSlot` dialect's ordered list level carries its\n // ROW_NUMBER() position as the LAST slot (the runtime sorts by it).\n const position = join.select.rowNumber;\n const positioned = position !== undefined && json.order === \"positionSlot\" && join.agg === \"jsonArray\" &&\n position.partitionBy.length === 0 && position.orderBy.length > 0;\n if (join.select.columns.length === 0 || join.select.selectExpr !== undefined ||\n (join.select.aggregates?.length ?? 0) > 0 || (position !== undefined && !positioned)) {\n throw internalError({ message: \"positional lateral rows require an explicit column-only projection\" });\n }\n const names = [...join.select.columns.map((column) => projectionOutputName({ column })), ...(positioned ? [position.alias] : [])];\n if (new Set(names).size !== names.length) {\n throw internalError({ message: \"positional lateral projection has duplicate output names\" });\n }\n const values = names.map((name) => `${subAlias}.${dialect.quoteIdent({ name })}`);\n const chunks: string[] = [];\n for (let index = 0; index < values.length; index += JSON_TRANSPORT.chunkSize) {\n chunks.push(`${json.rowArray}(${values.slice(index, index + JSON_TRANSPORT.chunkSize).join(\", \")})`);\n }\n if (chunks.length > JSON_TRANSPORT.chunkSize) {\n throw internalError({ message: \"positional lateral projection exceeds the transport width limit\" });\n }\n return chunks.length === 1 ? chunks[0] as string : `${json.rowArray}(${chunks.join(\", \")})`;\n}\n\n/** The dialect's lateral JSON functions; callers already refused a dialect without them. */\nfunction lateralJsonOf(params: { dialect: SqlDialect }): NonNullable<SqlDialect[\"lateralJson\"]> {\n const json = params.dialect.lateralJson;\n if (json === null) throw internalError({ message: \"lateral JSON rendering on a dialect without LATERAL\" });\n return json;\n}\n\nfunction renderLateralJoin(params: {\n dialect: SqlDialect;\n join: LateralJoin;\n collector: ParamCollector;\n}): string {\n const { dialect, join, collector } = params;\n const inner = renderSelect({ dialect, statement: join.select, collector });\n if (join.agg === \"count\") {\n if (join.rowFormat === \"positional\" || join.select.columns.length !== 0 ||\n join.select.selectExpr?.kind !== \"countAll\" || join.select.selectExpr.alias !== join.columnAlias ||\n join.select.groupBy !== undefined || join.select.having !== undefined ||\n join.select.limit !== undefined || join.select.offset !== undefined || join.select.distinctOn !== undefined ||\n join.select.distinct !== undefined) {\n throw internalError({ message: \"count lateral must return one ungrouped COUNT(*) under its column alias\" });\n }\n return `LEFT JOIN LATERAL (${inner.text}) AS ${dialect.quoteIdent({ name: join.alias })} ON true`;\n }\n const columnAlias = dialect.quoteIdent({ name: join.columnAlias });\n const subAlias = dialect.quoteIdent({ name: \"__sub\" });\n const json = lateralJsonOf({ dialect });\n // N2 (SQL review): json_agg over a subquery only \"usually\" preserves the\n // subquery's order — pin it with an explicit ORDER BY inside the aggregate\n // (the subquery keeps its own ORDER BY for LIMIT). Only column terms that\n // are PROJECTED (and untransformed — a B3 ::text cast would re-sort\n // lexicographically) can be referenced through `__sub`; anything else keeps\n // the old behavior. A `positionSlot` dialect (MySQL) orders through the\n // position slot instead ({@link renderPositionalRow}).\n let aggOrder = \"\";\n if (json.order === \"inAggregate\" && join.agg === \"jsonArray\" && join.select.orderBy !== undefined && join.select.orderBy.length > 0) {\n const projected = new Set(\n join.select.columns\n .filter((column) => column.transform === undefined && column.castReal !== true)\n .map((column) => column.name),\n );\n const terms = join.select.orderBy;\n const columnTerms = terms.filter(\n (term): term is Extract<OrderTerm, { column: ColRef }> => \"column\" in term,\n );\n if (columnTerms.length === terms.length && columnTerms.every((term) => projected.has(term.column.name))) {\n const rendered = columnTerms.map((term) =>\n renderOrderTerm({\n dialect,\n term: {\n ...term,\n column: { table: \"__sub\", name: term.column.name, ...(term.column.castJsonb === undefined ? {} : { castJsonb: term.column.castJsonb }) },\n },\n collector,\n }),\n );\n aggOrder = ` ORDER BY ${rendered.join(\", \")}`;\n }\n }\n if (join.rowFormat !== \"positional\" && json.order !== \"inAggregate\") {\n // `to_json(\"__sub\".*)` names the columns itself; the runtime always sends\n // positional rows, so object rows stay a postgres construct.\n throw unsupportedCapability({ dialect: dialect.name, feature: \"object-format lateral rows\", hint: \"lateral relation rows render positional (rowFormat \\\"positional\\\") on this dialect\" });\n }\n const rowJson = join.rowFormat === \"positional\"\n ? renderPositionalRow({ dialect, join, subAlias })\n : `to_json(${subAlias}.*)`;\n const projection =\n join.agg === \"jsonArray\"\n ? `COALESCE(${json.arrayAgg}(${rowJson}${aggOrder}), ${json.emptyArray}) AS ${columnAlias}`\n : `${rowJson} AS ${columnAlias}`;\n const alias = dialect.quoteIdent({ name: join.alias });\n return `LEFT JOIN LATERAL (SELECT ${projection} FROM (${inner.text}) AS ${subAlias}) AS ${alias} ON true`;\n}\n\n/**\n * `(SELECT COUNT(*) FROM … WHERE …) AS \"alias\"` — one scalar per output row\n * ({@link CountSubquery}). Refuses anything but one ungrouped COUNT(*), so a\n * builder bug can never project a multi-row or multi-column subquery.\n */\nfunction renderCountSubquery(params: {\n dialect: SqlDialect;\n subquery: CountSubquery;\n collector: ParamCollector;\n}): string {\n const { dialect, subquery, collector } = params;\n const select = subquery.select;\n if (select.columns.length !== 0 || select.selectExpr?.kind !== \"countAll\" ||\n (select.aggregates?.length ?? 0) > 0 || select.rowNumber !== undefined ||\n select.groupBy !== undefined || select.having !== undefined ||\n select.limit !== undefined || select.offset !== undefined ||\n select.distinctOn !== undefined || select.distinct !== undefined || select.rowLock !== undefined ||\n select.countSubqueries !== undefined) {\n throw internalError({ message: \"count subquery must be one ungrouped COUNT(*)\" });\n }\n const inner = renderSelect({ dialect, statement: select, collector });\n return `(${inner.text}) AS ${dialect.quoteIdent({ name: subquery.alias })}`;\n}\n\n// ─── RETURNING ────────────────────────────────────────────────────\n\nfunction applyReturning(params: {\n dialect: SqlDialect;\n requested: readonly ReturningColumn[] | undefined;\n}): { suffix: string; status: \"native\" | \"omitted\" | \"none\" } {\n const { dialect, requested } = params;\n if (requested === undefined || requested.length === 0) {\n return { suffix: \"\", status: \"none\" };\n }\n if (!dialect.capabilities.returning) {\n return { suffix: \"\", status: \"omitted\" };\n }\n const columns = requested\n .map((column) => {\n if (typeof column === \"string\") return dialect.quoteIdent({ name: column });\n if (\"transform\" in column) {\n const name = dialect.quoteIdent({ name: column.name });\n return `${dialect.jsonTextProjection({ expression: name })} AS ${name}`;\n }\n const name = dialect.quoteIdent({ name: column.name });\n return `${textProjection({ dialect, expression: name })} AS ${name}`;\n })\n .join(\", \");\n return { suffix: ` RETURNING ${columns}`, status: \"native\" };\n}\n\n// ─── SELECT ───────────────────────────────────────────────────────\n\n/**\n * {@link KeyTableJoin}: `INNER JOIN (VALUES ROW(?, 0), …) AS alias (…) ON …`.\n * Mysql only — the one dialect whose default text equality is not byte\n * equality, and the shape was measured there (8.0.19+ `VALUES ROW`, already\n * this project's floor for the upsert row alias). Postgres needs a typed\n * parameter per member, so it renders only `citext` / `text` / `integer`\n * members (`CAST($n AS citext | text | bigint)`, plain `(…)` rows) — the\n * runtime emits it for a key tuple with a citext member; every other postgres\n * member refuses, and sqlite has no derived-table column list, so it refuses\n * rather than render an untested form.\n *\n * Ordinals are literal integers (row `i` → `i`): a statement-local index, not\n * data, so a key costs exactly the parameters its members bind — the same\n * budget as `col IN (?, …)`. Text members bind bare so the column's collation\n * decides; numeric members that travel as strings are CAST (see\n * {@link KeyTableMember}).\n *\n * The runtime emits a key table wherever `conflictKeyEquality.textIsBinaryByDefault`\n * is false (packages/runtime/src/relation-loader.ts, `associatesInDatabase`);\n * this refusal is by NAME, so a new dialect declaring that fact must also be\n * measured and admitted here.\n */\nfunction renderKeyTableJoin(params: { dialect: SqlDialect; join: KeyTableJoin; collector: ParamCollector }): string {\n const { dialect, join, collector } = params;\n // Postgres binds every member typed (an untyped VALUES cell would be\n // `text`, see {@link KeyTableMember}); `citext` and `text` are postgres\n // members, mysql binds text bare.\n const postgresMember = (member: KeyTableMember): boolean => member.kind === \"citext\" || member.kind === \"text\" || member.kind === \"integer\";\n const admitted = dialect.name === \"mysql\"\n ? join.members.every((member) => member.kind !== \"citext\" && member.kind !== \"text\")\n : dialect.name === \"postgres\" && join.members.every(postgresMember);\n if (!admitted) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"relation key table\",\n hint: \"the key-table join is mysql's relation association — this dialect compares relation keys by value\",\n });\n }\n if (join.columns.length === 0 || join.columns.length !== join.members.length) {\n throw internalError({ message: `key table needs one member per column, got ${join.members.length} for ${join.columns.length}` });\n }\n if (join.rows.length === 0) throw internalError({ message: \"key table needs at least one key row\" });\n for (const member of join.members) {\n if (member.kind === \"decimal\" && !(Number.isInteger(member.scale) && member.scale >= 0 && member.scale <= 30)) {\n throw internalError({ message: `key table decimal scale must be an integer 0-30, got ${String(member.scale)}` });\n }\n }\n const alias = dialect.quoteIdent({ name: join.alias });\n const memberNames = join.members.map((_, index) => dialect.quoteIdent({ name: `__vibe_k${index}` }));\n const rows = join.rows.map((row, ordinal) => {\n if (row.length !== join.members.length) {\n throw internalError({ message: `key table row has ${row.length} values for ${join.members.length} members` });\n }\n const cells = row.map((value, index) => {\n const placeholder = collector.add(value);\n const member = join.members[index] as KeyTableMember;\n switch (member.kind) {\n case \"integer\":\n return dialect.name === \"mysql\" ? `CAST(${placeholder} AS SIGNED)` : `CAST(${placeholder} AS bigint)`;\n case \"timestamp\":\n return `CAST(${placeholder} AS DATETIME(6))`;\n case \"time\":\n return `CAST(${placeholder} AS TIME(6))`;\n case \"decimal\":\n return `CAST(${placeholder} AS DECIMAL(65,${member.scale}))`;\n case \"citext\":\n return `CAST(${placeholder} AS citext)`;\n case \"text\":\n return `CAST(${placeholder} AS text)`;\n default:\n return placeholder;\n }\n });\n return dialect.name === \"mysql\" ? `ROW(${cells.join(\", \")}, ${ordinal})` : `(${cells.join(\", \")}, ${ordinal})`;\n });\n const on = join.columns.map((column, index) => `${quoteCol(dialect, column)} = ${alias}.${memberNames[index] as string}`).join(\" AND \");\n return `INNER JOIN (VALUES ${rows.join(\", \")}) AS ${alias} (${[...memberNames, dialect.quoteIdent({ name: join.ordinalAlias })].join(\", \")}) ON ${on}`;\n}\n\n// ─── Fix lane Q2 (D-03): derived-table LEFT JOIN ───\n\n/**\n * {@link LeftJoin}: `LEFT JOIN (<select>) AS \"alias\" ON \"alias\".\"k\" =\n * \"outer\".\"c\" [AND …]`. Portable. Refuses a builder bug: no ON pair, or a\n * derived projection with an unaliased column (the outer scope must see only\n * the reserved aliases, never a name that could make an unqualified outer\n * reference ambiguous). The derived select renders here, so its parameters\n * land in the shared sequence where they appear in the text.\n */\nfunction renderLeftJoin(params: { dialect: SqlDialect; join: LeftJoin; collector: ParamCollector }): string {\n const { dialect, join, collector } = params;\n if (join.on.length === 0) {\n throw internalError({ message: \"left join needs at least one ON pair\" });\n }\n if (join.select.columns.length === 0 || join.select.columns.some((column) => column.alias === undefined)) {\n throw internalError({ message: \"a left join's derived select must alias every projected column\" });\n }\n const inner = renderSelect({ dialect, statement: join.select, collector });\n const on = join.on\n .map((pair) => `${quoteCol(dialect, pair.left)} = ${quoteCol(dialect, pair.right)}`)\n .join(\" AND \");\n return `LEFT JOIN (${inner.text}) AS ${dialect.quoteIdent({ name: join.alias })} ON ${on}`;\n}\n\nfunction renderSelect(params: {\n dialect: SqlDialect;\n statement: SelectStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n if (statement.selectExpr !== undefined && statement.columns.length > 0 && statement.selectExpr.kind !== \"countAll\") {\n throw internalError({ message: \"only countAll can combine with a column list\" });\n }\n if (\n statement.selectExpr !== undefined &&\n statement.aggregates !== undefined &&\n statement.aggregates.length > 0\n ) {\n throw internalError({ message: \"selectExpr and aggregates cannot combine\" });\n }\n const columnList = statement.columns.map((column) => quoteProjection(dialect, column));\n if (statement.selectExpr !== undefined) {\n columnList.push(renderSelectExpr({ dialect, expr: statement.selectExpr }));\n }\n if (statement.aggregates !== undefined) {\n for (const selection of statement.aggregates) {\n const expression = renderAggRef(dialect, selection.agg);\n const projected = selection.castText === true ? textProjection({ dialect, expression }) : expression;\n columnList.push(`${projected} AS ${dialect.quoteIdent({ name: selection.alias })}`);\n }\n }\n if (statement.countSubqueries !== undefined) {\n for (const subquery of statement.countSubqueries) {\n columnList.push(renderCountSubquery({ dialect, subquery, collector }));\n }\n }\n if (statement.rowNumber !== undefined) {\n const rowNumber = statement.rowNumber;\n // An unpartitioned window numbers the whole select: only the position slot\n // of a lateral list level (`lateralJson.order: \"positionSlot\"`), which\n // always carries the level's order.\n if (rowNumber.partitionBy.length === 0 && rowNumber.orderBy.length === 0) {\n throw internalError({ message: \"rowNumber needs a partition column or an order\" });\n }\n const partition = rowNumber.partitionBy.length === 0 ? \"\" : `PARTITION BY ${rowNumber.partitionBy.map((column) => quoteCol(dialect, column)).join(\", \")}`;\n const order =\n rowNumber.orderBy.length === 0\n ? \"\"\n : `${partition === \"\" ? \"\" : \" \"}ORDER BY ${rowNumber.orderBy.map((term) => renderOrderTerm({ dialect, term, collector })).join(\", \")}`;\n columnList.push(\n `ROW_NUMBER() OVER (${partition}${order}) AS ${dialect.quoteIdent({ name: rowNumber.alias })}`,\n );\n }\n let distinctPrefix = statement.distinct === true ? \"DISTINCT \" : \"\";\n if (statement.distinct === true && statement.distinctOn !== undefined) {\n throw internalError({ message: \"distinct and distinctOn cannot combine\" });\n }\n if (statement.distinctOn !== undefined && statement.distinctOn.length > 0) {\n if (!dialect.capabilities.distinctOn) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"SELECT DISTINCT ON\",\n hint: \"postgres-only — the runtime emulates distinct client-side on this dialect\",\n });\n }\n distinctPrefix = `DISTINCT ON (${statement.distinctOn.map((column) => quoteCol(dialect, typedOrderRef({ statement, column }))).join(\", \")}) `;\n }\n const columns = columnList.length === 0 ? \"*\" : columnList.join(\", \");\n\n let from: string;\n // EPIC 4 (ST-07): key rows render where the table would, under its name.\n if (statement.fromKeys !== undefined) {\n from = renderKeyRows({ dialect, statement, keys: statement.fromKeys, collector });\n } else if (statement.fromUnion !== undefined) {\n // Fix lane Q2 (DB-07): a union page renders where a derived table would.\n from = `(${renderUnionPage({ dialect, statement, collector })}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else if (statement.keyPage !== undefined) {\n // Fix lane Q1 (DB-01): a per-key page renders where a derived table would.\n if (statement.fromSelect !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"keyPage uses table.name as the derived-table alias — fromSelect and table.alias must be unset\" });\n }\n from = `(${renderKeyPage({ dialect, page: statement.keyPage, collector })}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else if (statement.fromSelect !== undefined) {\n if (statement.table.alias !== undefined) {\n throw internalError({ message: \"fromSelect uses table.name as the subquery alias — table.alias must be unset\" });\n }\n // The subquery renders before WHERE/ORDER BY, so its parameters land in\n // the shared sequence exactly where they appear in the text.\n const inner = renderSelect({ dialect, statement: statement.fromSelect, collector });\n from = `(${inner.text}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else {\n from = renderTable(dialect, statement.table);\n }\n let text = `SELECT ${distinctPrefix}${columns} FROM ${from}`;\n\n if (statement.innerJoins !== undefined && statement.innerJoins.length > 0) {\n for (const join of statement.innerJoins) {\n if (join.on.length === 0) {\n throw internalError({ message: \"inner join needs at least one ON pair\" });\n }\n const on = join.on\n .map((pair) => `${quoteCol(dialect, pair.left)} = ${quoteCol(dialect, pair.right)}`)\n .join(\" AND \");\n text += ` INNER JOIN ${renderTable(dialect, join.table)} ON ${on}`;\n }\n }\n if (statement.keyTable !== undefined) {\n text += ` ${renderKeyTableJoin({ dialect, join: statement.keyTable, collector })}`;\n }\n // Fix lane Q2 (D-03): derived-table LEFT JOINs (to-one relation orderBy).\n if (statement.leftJoins !== undefined && statement.leftJoins.length > 0) {\n if (statement.rowLock !== undefined) {\n throw internalError({ message: \"a locking read cannot carry a left join — postgres refuses FOR UPDATE on the nullable side of an outer join\" });\n }\n for (const join of statement.leftJoins) {\n text += ` ${renderLeftJoin({ dialect, join, collector })}`;\n }\n }\n\n if (statement.lateralJoins !== undefined && statement.lateralJoins.length > 0) {\n if (!dialect.capabilities.lateralJoin || dialect.lateralJson === null) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"LATERAL JOIN relation loading\",\n hint: 'use the portable \"query\" relation strategy on this dialect',\n });\n }\n for (const join of statement.lateralJoins) {\n text += ` ${renderLateralJoin({ dialect, join, collector })}`;\n }\n }\n\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n if (statement.groupBy !== undefined && statement.groupBy.length > 0) {\n text += ` GROUP BY ${statement.groupBy.map((column) => quoteCol(dialect, column)).join(\", \")}`;\n }\n if (statement.having !== undefined) {\n text += ` HAVING ${renderExpr({ dialect, expr: statement.having, collector })}`;\n }\n if (statement.orderBy !== undefined && statement.orderBy.length > 0) {\n const terms = statement.orderBy.map((term) =>\n renderOrderTerm({ dialect, term: \"column\" in term ? { ...term, column: typedOrderRef({ statement, column: term.column }) } : term, collector }),\n );\n text += ` ORDER BY ${terms.join(\", \")}`;\n }\n\n if (statement.limit !== undefined) {\n assertCount(statement.limit, \"limit\");\n text += ` LIMIT ${statement.limit}`;\n }\n if (statement.offset !== undefined) {\n assertCount(statement.offset, \"offset\");\n if (statement.limit === undefined && dialect.offsetRequiresLimit !== null) {\n text += ` LIMIT ${dialect.offsetRequiresLimit.limitText}`;\n }\n text += ` OFFSET ${statement.offset}`;\n }\n if (statement.rowLock !== undefined) {\n const clause = renderRowLockClause({ dialect, lock: statement.rowLock });\n if (clause !== null) text += ` ${clause}`;\n }\n\n return { text, values: collector.values, returning: \"none\" };\n}\n\n// ─── INSERT (incl. upsert) ────────────────────────────────────────\n\n/** The unnest source's relation alias and its ordinality column (`InsertStatement.unnest`). */\nconst UNNEST_ROWS_ALIAS = \"__vibe_rows\";\nconst UNNEST_ORDINALITY = \"ord\";\n\n/**\n * One cell of an unnest insert, as its array element: a plain value, SQL NULL,\n * or a Json cell's text (the column's storage must match). `DEFAULT`, the\n * database clock and any other object are refused — the builder keeps VALUES\n * for them, so reaching here is a builder defect.\n */\nfunction unnestElement(params: { value: unknown; column: string; jsonStorage: \"json\" | \"jsonb\" | undefined }): unknown {\n const { value, column, jsonStorage } = params;\n if (value === null || value === undefined) return null;\n if (isJsonParamCell(value)) {\n if (jsonStorage === undefined || (value.storage ?? \"jsonb\") !== jsonStorage) {\n throw internalError({ message: `unnest insert column \"${column}\" got a Json cell its declared type does not take` });\n }\n return value.text;\n }\n if (jsonStorage === undefined) {\n switch (typeof value) {\n case \"string\":\n case \"number\":\n case \"boolean\":\n case \"bigint\":\n return value;\n case \"object\":\n if (value instanceof Date || value instanceof Uint8Array) return value;\n }\n }\n throw internalError({ message: `unnest insert column \"${column}\" got a cell that is not a plain value (DEFAULT, the database clock, a document) — such rows keep VALUES` });\n}\n\n/**\n * `SELECT \"c1\", … FROM unnest($1::<type>[], …) WITH ORDINALITY AS\n * \"__vibe_rows\" (\"c1\", …, \"ord\") ORDER BY \"ord\"` — the source of an\n * {@link InsertStatement} carrying `unnest`. Collects ONE array per column, in\n * column order: the rows transposed, Json cells reduced to their text. The\n * aliases are positional, so no column name can collide with the ordinality\n * column; `ORDER BY \"ord\"` makes the insert consume rows in input order\n * (PostgreSQL promises no order without it).\n */\nfunction renderUnnestRows(params: {\n dialect: SqlDialect;\n statement: InsertStatement;\n members: readonly KeyListMember[];\n collector: ParamCollector;\n}): string {\n const { dialect, statement, members, collector } = params;\n if (dialect.bulkInsertForm !== \"unnest\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a bulk insert bound as typed arrays (INSERT … SELECT FROM unnest)\",\n hint: \"this dialect binds createMany rows as VALUES\",\n });\n }\n if (statement.columns.length === 0) throw internalError({ message: \"an unnest insert needs at least one column\" });\n if (members.length !== statement.columns.length) {\n throw internalError({ message: `unnest insert has ${members.length} column types for ${statement.columns.length} columns` });\n }\n if (statement.onConflict !== undefined && !(\"doNothing\" in statement.onConflict)) {\n throw internalError({ message: \"an unnest insert takes no DO UPDATE arm — upserts bind VALUES\" });\n }\n const aliases = statement.columns.map((_column, index) => dialect.quoteIdent({ name: `c${index + 1}` }));\n const arrays = members.map((member, index) => {\n const cast = postgresBulkInsertArrayCast({ dialect, member });\n const jsonStorage = member.type !== \"Json\" ? undefined : cast === \"text::json\" ? \"json\" : \"jsonb\";\n const column = statement.columns[index] as string;\n const values = statement.rows.map((row) => unnestElement({ value: row[index], column, jsonStorage }));\n return `${collector.add(values)}::${cast}[]`;\n });\n const ord = dialect.quoteIdent({ name: UNNEST_ORDINALITY });\n return `SELECT ${aliases.join(\", \")} FROM unnest(${arrays.join(\", \")}) WITH ORDINALITY AS ${dialect.quoteIdent({ name: UNNEST_ROWS_ALIAS })} (${aliases.join(\", \")}, ${ord}) ORDER BY ${ord}`;\n}\n\nfunction renderInsert(params: {\n dialect: SqlDialect;\n statement: InsertStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n if (statement.rows.length === 0) {\n throw internalError({ message: \"insert requires at least one row\" });\n }\n // No column named: every value is its column default (dialect.emptyInsert).\n const defaultValues = statement.columns.length === 0 && dialect.emptyInsert.form === \"defaultValues\";\n if (defaultValues && statement.rows.length !== 1) {\n throw internalError({ message: `${dialect.name} inserts an all-default row as DEFAULT VALUES, one row per statement` });\n }\n if (defaultValues && statement.onConflict !== undefined && !(dialect.emptyInsert.form === \"defaultValues\" && dialect.emptyInsert.conflictClause)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a conflict clause on an all-default row (DEFAULT VALUES)\",\n hint: \"supply at least one column value, or drop the conflict clause\",\n });\n }\n for (const row of statement.rows) {\n if (row.length !== statement.columns.length) {\n throw internalError({\n message: `insert row has ${row.length} values but ${statement.columns.length} columns`,\n });\n }\n }\n\n const onConflict = statement.onConflict;\n const insertKeyword = \"INSERT INTO\";\n\n const columnList = statement.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n // EPIC C: rows bound as one typed array per column (`InsertStatement.unnest`).\n const unnestSource = statement.unnest === undefined ? undefined : renderUnnestRows({ dialect, statement, members: statement.unnest, collector });\n const rowsSql = unnestSource !== undefined ? \"\" : statement.rows\n .map(\n (row) =>\n `(${row\n .map((value) => {\n // Json cell: the param's type is pinned (`$n::text::jsonb` on\n // postgres) so OID-typed drivers cannot double-encode the document.\n if (isJsonParamCell(value)) return `${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n // Database-clock cell: the dialect's now() expression.\n if (isDbNowMarker(value)) {\n return dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector });\n }\n if (!isSqlDefaultCell(value)) return collector.add(value);\n // M4: a heterogeneous createMany cell defers to the COLUMN default.\n if (!dialect.rowDefaultKeyword) {\n throw internalError({\n message: `${dialect.name} cannot render a per-row DEFAULT cell — rows must be grouped by column set`,\n });\n }\n return \"DEFAULT\";\n })\n .join(\", \")})`,\n )\n .join(\", \");\n let text = defaultValues\n ? `${insertKeyword} ${renderTable(dialect, statement.table)} DEFAULT VALUES`\n : `${insertKeyword} ${renderTable(dialect, statement.table)} (${columnList}) ${unnestSource ?? `VALUES ${rowsSql}`}`;\n\n // Mysql can only name the incoming row through a ROW ALIAS declared right\n // after the VALUES list; postgres/sqlite have the built-in `excluded`\n // pseudo-relation and need nothing. Emitted only when the update arm\n // actually references the incoming row.\n if (\n onConflict !== undefined &&\n !(\"doNothing\" in onConflict) &&\n dialect.excludedRowRef.form === \"rowAlias\" &&\n Object.values(onConflict.update).some((value) => isExcludedRef(value) || (isSqlFragment(value) && sqlUsesIncoming({ fragment: value })))\n ) {\n text += ` AS ${dialect.quoteIdent({ name: dialect.excludedRowRef.alias })}`;\n }\n\n if (onConflict !== undefined) {\n if (\"doNothing\" in onConflict) {\n if (dialect.doNothingForm === \"onConflictDoNothing\") {\n let target = \"\";\n if (onConflict.constraint !== undefined) {\n if (dialect.name !== \"postgres\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target (ON CONFLICT ON CONSTRAINT)\",\n hint: \"only postgres names constraints in conflict targets — use a column-list target\",\n });\n }\n target = ` ON CONSTRAINT ${dialect.quoteIdent({ name: onConflict.constraint })}`;\n } else if (onConflict.columns !== undefined && onConflict.columns.length > 0) {\n target = ` (${onConflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")})`;\n if (onConflict.conflictWhere !== undefined) {\n // RAW predicate — the engines match it against the index's own\n // predicate structurally; parameters could never match (ast.ts).\n target += ` WHERE ${onConflict.conflictWhere}`;\n }\n }\n text += ` ON CONFLICT${target} DO NOTHING`;\n } else {\n // `duplicateKeyKeep` fires on ANY duplicate key. A bare column target\n // degrades to that documented wider skip; a REFINED target (named\n // constraint, partial-index predicate) must not silently widen —\n // the builder gates first, the renderer defends.\n if (onConflict.constraint !== undefined || onConflict.conflictWhere !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a refined conflict target (constraint / partial-index predicate) on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql skips on any duplicate key — drop the refinement or gate the call per dialect\",\n });\n }\n // A self-assignment: a duplicate changes nothing, every other error\n // (NOT NULL, range, foreign key) stays an error — never INSERT IGNORE.\n const keepName = onConflict.keepColumn ?? statement.columns[0];\n if (keepName === undefined) {\n throw internalError({ message: \"a skip-duplicates insert of an all-default row must name its keepColumn\" });\n }\n const keep = dialect.quoteIdent({ name: keepName });\n const current = `${dialect.quoteIdent({ name: statement.table.name })}.${keep}`;\n const flag = onConflict.duplicateFlag;\n if (flag !== undefined && !/^\\d{1,20}$/.test(flag)) {\n throw internalError({ message: `duplicateFlag must be a decimal literal, got ${JSON.stringify(flag)}` });\n }\n // The flag form reports a skipped duplicate through the insert id\n // (`LAST_INSERT_ID(S)` runs only on the duplicate arm).\n text += flag === undefined\n ? ` ON DUPLICATE KEY UPDATE ${keep} = ${current}`\n : ` ON DUPLICATE KEY UPDATE ${keep} = IF(LAST_INSERT_ID(${flag}), ${current}, ${current})`;\n }\n } else {\n const updates = Object.entries(onConflict.update);\n if (updates.length === 0) {\n throw internalError({ message: \"upsert update must set at least one column\" });\n }\n // The update arm's self-references MUST be table-qualified: inside\n // `ON CONFLICT … DO UPDATE SET`, postgres has BOTH the target row and\n // the `excluded` pseudo-relation in scope, so a bare `\"views\" + $n`\n // is rejected as ambiguous (SQLSTATE 42702). Sqlite and mysql accept\n // the qualified form with identical semantics (the pre-update row), so\n // one rule covers every dialect instead of a per-dialect divergence.\n const selfRef = dialect.quoteIdent({ name: statement.table.name });\n const assignments = renderAssignments({ dialect, entries: updates, collector, selfRef, allowExcluded: true, tableName: statement.table.name });\n if (dialect.upsertForm === \"onConflict\") {\n if (onConflict.lastInsertIdColumn !== undefined) {\n throw internalError({ message: \"lastInsertIdColumn is a mysql (onDuplicateKey) construct\" });\n }\n if (onConflict.constraint !== undefined && dialect.name !== \"postgres\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target (ON CONFLICT ON CONSTRAINT)\",\n hint: \"sqlite conflict targets are column lists — name the indexed columns instead\",\n });\n }\n if (onConflict.constraint !== undefined && onConflict.conflictWhere !== undefined) {\n throw internalError({\n message: \"a named-constraint conflict target already identifies the index — it cannot carry a partial predicate too\",\n });\n }\n // RAW predicate — matched structurally against the partial index's own\n // stored predicate, exactly like the DO NOTHING form (ast.ts).\n const partial = onConflict.conflictWhere === undefined ? \"\" : ` WHERE ${onConflict.conflictWhere}`;\n const target =\n onConflict.constraint !== undefined\n ? ` ON CONSTRAINT ${dialect.quoteIdent({ name: onConflict.constraint })}`\n : ` (${onConflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")})${partial}`;\n text += ` ON CONFLICT${target} DO UPDATE SET ${assignments}`;\n } else {\n if (onConflict.constraint !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql's ODKU fires on any duplicate key — no target can be named\",\n });\n }\n if (onConflict.conflictWhere !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a partial-index conflict target on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql's ODKU fires on any duplicate key — a partial arbiter cannot be selected; gate the call per dialect\",\n });\n }\n // B2: the update arm must record WHICH row it addressed — without this,\n // LAST_INSERT_ID() is stale after ODKU takes the update arm and the\n // read-back can resolve an unrelated row.\n const trick =\n onConflict.lastInsertIdColumn === undefined\n ? \"\"\n : `, ${dialect.quoteIdent({ name: onConflict.lastInsertIdColumn })} = LAST_INSERT_ID(${dialect.quoteIdent({ name: onConflict.lastInsertIdColumn })})`;\n text += ` ON DUPLICATE KEY UPDATE ${assignments}${trick}`;\n }\n }\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── UPDATE ───────────────────────────────────────────────────────\n\nfunction renderUpdate(params: {\n dialect: SqlDialect;\n statement: UpdateStatement;\n collector: ParamCollector;\n /** Chain steps defined before this one (a chain step only): a set value may read them. */\n earlier?: ReadonlySet<string>;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n const assignments = Object.entries(statement.set);\n if (assignments.length === 0) {\n throw internalError({ message: \"update must set at least one column\" });\n }\n const setSql = renderAssignments({ dialect, entries: assignments, collector, ...(params.earlier === undefined ? {} : { steps: params.earlier }) });\n let text = `UPDATE ${renderTable(dialect, statement.table)} SET ${setSql}`;\n\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── Assignments (SET / DO UPDATE SET) ────────────────────────────\n\n/**\n * `SET` assignments, shared by UPDATE and the upsert update arm.\n *\n * `selfRef` (the quoted target table) qualifies the READ side of an operation\n * that reads the column it writes — required inside `ON CONFLICT DO UPDATE`,\n * where a bare reference is ambiguous with `excluded` on postgres. The write\n * side is never qualified: `SET \"t\".\"col\" = …` is a syntax error everywhere.\n * A plain UPDATE passes no `selfRef` — it has no second relation in scope.\n */\n/**\n * The incoming row's column, qualified for this dialect: `excluded.\"col\"`\n * (postgres/sqlite) or `` `new`.`col` `` (mysql's row alias, declared after the\n * VALUES list by {@link renderInsert}).\n */\nfunction renderIncomingRowColumn(params: { dialect: SqlDialect; column: string }): string {\n const { dialect, column } = params;\n const ref = dialect.excludedRowRef;\n const qualifier = ref.form === \"keyword\" ? ref.name : dialect.quoteIdent({ name: ref.alias });\n return `${qualifier}.${dialect.quoteIdent({ name: column })}`;\n}\n\nfunction renderAssignments(params: {\n dialect: SqlDialect;\n entries: readonly (readonly [string, unknown])[];\n collector: ParamCollector;\n selfRef?: string;\n /** Only an upsert's update arm has an incoming row to reference. */\n allowExcluded?: boolean;\n tableName?: string;\n /** Lane C3: earlier chain steps a {@link StepColumnRef} value may read (a chain UPDATE step only). */\n steps?: ReadonlySet<string>;\n}): string {\n const { dialect, entries, collector, selfRef } = params;\n return entries\n .map(([name, value]) => {\n const column = dialect.quoteIdent({ name });\n const read = selfRef === undefined ? column : `${selfRef}.${column}`;\n // Lane C3: the value of an earlier step's one row — a scalar subquery,\n // whose own scope resolves the column (no clash with the target's).\n if (isStepColumnRef(value)) {\n if (params.steps === undefined || !params.steps.has(value.step)) {\n throw internalError({ message: `an UPDATE set value reads step \"${value.step}\", which is not an earlier chain step` });\n }\n return `${column} = (SELECT ${dialect.quoteIdent({ name: value.column })} FROM ${dialect.quoteIdent({ name: value.step })})`;\n }\n // The INCOMING row's value for this column — a column reference, so a\n // batched upsert writes each conflicting row's own value while binding\n // it exactly once (in the VALUES list).\n if (isSqlFragment(value)) {\n if (params.allowExcluded !== true || selfRef === undefined) throw internalError({ message: \"SQL assignment fragments require a conflict update\" });\n return `${column} = ${renderSqlFragment({ dialect, fragment: value, collector, conflict: { table: params.tableName! } })}`;\n }\n if (isExcludedRef(value)) {\n if (params.allowExcluded !== true) {\n throw internalError({\n message: `an incoming-row reference (${value.column}) is only meaningful inside an upsert's update arm`,\n });\n }\n return `${column} = ${renderIncomingRowColumn({ dialect, column: value.column })}`;\n }\n // V8: the column keeps its current value — a conflict update arm only.\n if (isSqlKeepCell(value)) {\n if (params.allowExcluded !== true || selfRef === undefined) throw internalError({ message: \"a keep-column cell is only meaningful inside an upsert's update arm\" });\n return `${column} = ${read}`;\n }\n // Json cell: same param-type pinning as the VALUES cells above.\n if (isJsonParamCell(value)) {\n return `${column} = ${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n }\n if (isSetOperation(value)) {\n const operand = collector.add(value.value);\n const numeric = dialect.name === \"sqlite\" && value.numericType === \"Decimal\" ? `CAST(${operand} AS REAL)` : operand;\n return `${column} = ${read} ${SET_OPERATION_SQL[value.__op]} ${numeric}`;\n }\n if (isDbNowMarker(value)) {\n return `${column} = ${dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector })}`;\n }\n if (isListSetOperation(value)) {\n assertScalarArrays(dialect, 'the scalar-list update operation \"push\"');\n if (value.__listOp === \"append\") {\n return `${column} = array_append(${read}, ${collector.add(value.value)})`;\n }\n return `${column} = ${read} || ${collector.add(value.value)}`;\n }\n return `${column} = ${collector.add(value)}`;\n })\n .join(\", \");\n}\n\n// ─── DELETE ───────────────────────────────────────────────────────\n\nfunction renderDelete(params: {\n dialect: SqlDialect;\n statement: DeleteStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n let text = `DELETE FROM ${renderTable(dialect, statement.table)}`;\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── Statement chains (WITH … SELECT) ─────────────────────────────\n\n/** Derived-table aliases of a chain's verdict SELECT — no step may take them. */\nconst CHAIN_ROWS_ALIAS = \"__vibe_rows\";\nconst CHAIN_ONE_ALIAS = \"__vibe_one\";\n\n/**\n * `WITH \"a\" AS (…), \"b\" AS (…) <final SELECT>` — see {@link ChainStatement}.\n * Steps render in order through the ordinary statement renderers on ONE\n * shared collector, so parameters number in step order, then the verdict.\n *\n * The verdict form is `SELECT rows.cols, <verdict> FROM (SELECT 1) LEFT JOIN\n * (<union>) AS rows ON TRUE`: one row per written row, or ONE all-NULL row\n * carrying the verdict when the union is empty. A `LEFT JOIN`, not a NULL\n * marker branch inside the `UNION ALL`, so every column keeps its RETURNING\n * type — PostgreSQL resolves a nested UNION's untyped NULLs pairwise (two NULL\n * branches become `text`), which a bare marker branch would trip over.\n */\nfunction renderChain(params: {\n dialect: SqlDialect;\n statement: ChainStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n if (dialect.statementChain === null) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a statement chain (data-modifying WITH steps)\",\n hint: \"this dialect accepts only SELECT inside WITH — gate on SqlDialect.statementChain and keep the multi-statement path\",\n });\n }\n if (statement.steps.length === 0) throw internalError({ message: \"a statement chain needs at least one step\" });\n const defined = new Set<string>();\n const steps: string[] = [];\n for (const step of statement.steps) {\n if (step.name === CHAIN_ROWS_ALIAS || step.name === CHAIN_ONE_ALIAS || defined.has(step.name)) {\n throw internalError({ message: `chain step name \"${step.name}\" is reserved or repeated` });\n }\n const body = renderChainStep({ dialect, statement: step.statement, collector, earlier: defined });\n steps.push(`${dialect.quoteIdent({ name: step.name })} AS (${body})`);\n defined.add(step.name);\n }\n\n const result = statement.result;\n if (result.rowsFrom.length === 0 || result.columns.length === 0) {\n throw internalError({ message: \"a chain result needs at least one source step and one column\" });\n }\n for (const name of result.rowsFrom) {\n if (!defined.has(name)) throw internalError({ message: `chain result reads undefined step \"${name}\"` });\n }\n const columnList = result.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n const union = result.rowsFrom\n .map((name) => `SELECT ${columnList} FROM ${dialect.quoteIdent({ name })}`)\n .join(\" UNION ALL \");\n let select = union;\n if (result.verdict !== undefined || result.tally !== undefined || (result.veto !== undefined && result.veto.length > 0)) {\n const extra: string[] = [];\n for (const alias of [result.verdict?.alias, result.tally?.alias]) {\n if (alias !== undefined && result.columns.includes(alias)) {\n throw internalError({ message: `chain result alias \"${alias}\" collides with a result column` });\n }\n }\n const rows = dialect.quoteIdent({ name: CHAIN_ROWS_ALIAS });\n const projected = result.columns.map((name) => `${rows}.${dialect.quoteIdent({ name })}`);\n if (result.verdict !== undefined) {\n extra.push(`${renderExpr({ dialect, expr: result.verdict.expr, collector })} AS ${dialect.quoteIdent({ name: result.verdict.alias })}`);\n }\n if (result.tally !== undefined || (result.veto !== undefined && result.veto.length > 0)) {\n extra.push(renderTallyColumn({ dialect, result, defined, collector }));\n }\n select =\n `SELECT ${[...projected, ...extra].join(\", \")} FROM (SELECT 1) AS ${dialect.quoteIdent({ name: CHAIN_ONE_ALIAS })}` +\n ` LEFT JOIN (${union}) AS ${rows} ON TRUE`;\n }\n return { text: `WITH ${steps.join(\", \")} ${select}`, values: collector.values, returning: \"none\" };\n}\n\nfunction renderChainStep(params: {\n dialect: SqlDialect;\n statement: ChainStepStatement;\n collector: ParamCollector;\n earlier: ReadonlySet<string>;\n}): string {\n const { dialect, statement, collector } = params;\n switch (statement.kind) {\n case \"select\":\n return renderSelect({ dialect, statement, collector }).text;\n case \"insert\":\n return renderInsert({ dialect, statement, collector }).text;\n case \"insertSelect\":\n return renderInsertSelect({ dialect, statement, collector, earlier: params.earlier });\n case \"update\":\n return renderUpdate({ dialect, statement, collector, earlier: params.earlier }).text;\n case \"delete\":\n return renderDelete({ dialect, statement, collector }).text;\n }\n}\n\n/** One SELECT-list cell in a VALUES form: encoded value, Json cell or clock cell — never DEFAULT. */\nfunction renderSelectCell(params: { dialect: SqlDialect; value: unknown; collector: ParamCollector }): string {\n const { dialect, value, collector } = params;\n if (isJsonParamCell(value)) return `${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n if (isDbNowMarker(value)) return dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector });\n if (isSqlDefaultCell(value)) {\n throw internalError({ message: \"DEFAULT is not allowed in an INSERT … SELECT list — omit the column instead\" });\n }\n return collector.add(value);\n}\n\n/**\n * `(SELECT cols FROM (VALUES (<typed NULL row>), ($1, $2), …) AS \"alias\"\n * (cols) OFFSET 1) AS \"alias\"` — see {@link ChainRowSource}: the first VALUES\n * row is one `(SELECT \"col\" FROM typedBy WHERE FALSE)` per column (a typed\n * NULL), which types every later parameter by the target table's own column;\n * `OFFSET 1` drops it again.\n */\nfunction renderRowSource(params: { dialect: SqlDialect; source: ChainRowSource; collector: ParamCollector }): string {\n const { dialect, source, collector } = params;\n if (source.columns.length === 0 || source.rows.length === 0) {\n throw internalError({ message: \"a row source needs at least one column and one row\" });\n }\n const typedBy = renderTable(dialect, source.typedBy);\n const columns = source.columns.map((name) => dialect.quoteIdent({ name }));\n const rows = [`(${columns.map((column) => `(SELECT ${column} FROM ${typedBy} WHERE FALSE)`).join(\", \")})`];\n for (const row of source.rows) {\n if (row.length !== source.columns.length) {\n throw internalError({ message: `row source row has ${row.length} values but ${source.columns.length} columns` });\n }\n rows.push(`(${row.map((value) => renderSelectCell({ dialect, value, collector })).join(\", \")})`);\n }\n const alias = dialect.quoteIdent({ name: source.alias });\n const columnList = columns.join(\", \");\n return `(SELECT ${columnList} FROM (VALUES ${rows.join(\", \")}) AS ${alias} (${columnList}) OFFSET 1) AS ${alias}`;\n}\n\n/**\n * The tally column guarded by the vetoes: `CASE WHEN NOT EXISTS (SELECT 1\n * FROM \"s\") THEN CAST('__vibe_veto:<token>:' || $n || ':' || (SELECT count(*)\n * FROM \"s\") AS integer) … ELSE (SELECT count(*) FROM \"a\") + … END`, `$n`\n * binding the veto's nonce. A veto with `minRows` above 1 (EPIC W) tests\n * `WHEN (SELECT count(*) FROM \"s\") < <minRows>` instead.\n *\n * The failing cast is how a plain SQL expression raises an error (SQLSTATE\n * 22P02, the marker quoted in the message). Its operand reads the step, so it\n * is NOT a constant: PostgreSQL folds constant CASE arms at plan time and\n * would raise even when the arm is never taken; this one is evaluated only\n * when its WHEN holds. The count it appends is the rows the step returned.\n */\nfunction renderTallyColumn(params: { dialect: SqlDialect; result: ChainResult; defined: ReadonlySet<string>; collector: ParamCollector }): string {\n const { dialect, result, defined, collector } = params;\n const tally = result.tally;\n if (tally === undefined) throw internalError({ message: \"a chain veto needs a tally column to guard\" });\n if (tally.steps.length === 0) throw internalError({ message: \"a chain tally needs at least one step\" });\n const step = (name: string): string => {\n if (!defined.has(name)) throw internalError({ message: `chain tally or veto reads undefined step \"${name}\"` });\n return dialect.quoteIdent({ name });\n };\n const count = (name: string): string => `(SELECT count(*) FROM ${step(name)})`;\n const sum = tally.steps.map(count).join(\" + \");\n const vetoes = result.veto ?? [];\n if (vetoes.length === 0) return `${sum} AS ${dialect.quoteIdent({ name: tally.alias })}`;\n const arms = vetoes.map((veto) => {\n if (!CHAIN_VETO_TOKEN_PATTERN.test(veto.token)) throw internalError({ message: `chain veto token \"${veto.token}\" is not a lower-case word` });\n if (typeof veto.nonce !== \"string\" || veto.nonce === \"\") throw internalError({ message: `chain veto \"${veto.token}\" needs a non-empty nonce` });\n const minRows = veto.minRows ?? 1;\n if (!Number.isSafeInteger(minRows) || minRows < 1) throw internalError({ message: `chain veto \"${veto.token}\" needs a positive integer minRows` });\n const when = minRows === 1 ? `WHEN NOT EXISTS (SELECT 1 FROM ${step(veto.step)})` : `WHEN ${count(veto.step)} < ${minRows}`;\n return `${when} THEN CAST('${CHAIN_VETO_PREFIX}${veto.token}:' || ${collector.add(veto.nonce)} || ':' || ${count(veto.step)} AS integer)`;\n });\n return `CASE ${arms.join(\" \")} ELSE ${sum} END AS ${dialect.quoteIdent({ name: tally.alias })}`;\n}\n\n/** `INSERT INTO t (cols) SELECT <cells> [FROM steps] [WHERE …] [RETURNING …]` — a chain step only. */\nfunction renderInsertSelect(params: {\n dialect: SqlDialect;\n statement: InsertSelectStatement;\n collector: ParamCollector;\n earlier: ReadonlySet<string>;\n}): string {\n const { dialect, statement, collector } = params;\n if (statement.columns.length === 0) throw internalError({ message: \"insert requires at least one column\" });\n if (statement.cells.length !== statement.columns.length) {\n throw internalError({\n message: `insert row has ${statement.cells.length} values but ${statement.columns.length} columns`,\n });\n }\n const from = statement.from ?? [];\n for (const name of from) {\n if (!params.earlier.has(name)) throw internalError({ message: `INSERT … SELECT reads step \"${name}\" before it is defined` });\n }\n const source = statement.source;\n if (source !== undefined && (params.earlier.has(source.alias) || from.includes(source.alias))) {\n throw internalError({ message: `row source alias \"${source.alias}\" collides with a chain step` });\n }\n const cells = statement.cells.map((value) => {\n if (isStepColumnRef(value)) {\n if (!from.includes(value.step) && value.step !== source?.alias) {\n throw internalError({ message: `cell reads step \"${value.step}\", which the INSERT … SELECT does not name in FROM` });\n }\n return `${dialect.quoteIdent({ name: value.step })}.${dialect.quoteIdent({ name: value.column })}`;\n }\n return renderSelectCell({ dialect, value, collector });\n });\n const columnList = statement.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n let text = `INSERT INTO ${renderTable(dialect, statement.table)} (${columnList}) SELECT ${cells.join(\", \")}`;\n const relations = from.map((name) => dialect.quoteIdent({ name }));\n if (source !== undefined) relations.push(renderRowSource({ dialect, source, collector }));\n if (relations.length > 0) text += ` FROM ${relations.join(\" CROSS JOIN \")}`;\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n const conflict = statement.conflictDoNothing;\n if (conflict !== undefined) {\n if (conflict.columns.length === 0) throw internalError({ message: \"an INSERT … SELECT conflict clause needs at least one column\" });\n if (dialect.doNothingForm !== \"onConflictDoNothing\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"ON CONFLICT DO NOTHING on an INSERT … SELECT chain step\",\n hint: \"gate on SqlDialect.statementChain and keep the multi-statement path\",\n });\n }\n text += ` ON CONFLICT (${conflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")}) DO NOTHING`;\n }\n return text + applyReturning({ dialect, requested: statement.returning }).suffix;\n}\n",
61
+ "import { renderSqliteJsonEquality } from \"./dialects/sqlite-json-equality.ts\";\nimport { JSON_TRANSPORT, projectionOutputName } from \"./json-transport.ts\";\nimport { isFixedDiagnostic, renderDiagnostic } from \"./dialects/diagnostics.ts\";\nimport type { DiagnosticStatement } from \"./dialects/diagnostics.ts\";\nimport { renderPostgresExplain, renderPostgresWorkload } from \"./dialects/postgres-diagnostics.ts\";\nimport { renderRlsReadinessQuery, renderRlsProbeTable, renderRlsPolicyPath } from \"./dialects/postgres-rls-readiness.ts\";\n/**\n * Statement renderer: SQL AST × dialect → { text, values, returning }.\n *\n * The shared grammar lives here; every dialect divergence goes through an\n * explicit SqlDialect strategy field. Malformed ASTs throw VIBE_INTERNAL —\n * the AST is built by VibeORM code, so a bad shape is always our bug.\n */\n\nimport { assertSqlNamespace, internalError, unsupportedCapability } from \"@vibeorm/schema\";\nimport { isSqlFragment, renderSqlFragment, sqlUsesIncoming } from \"./composable.ts\";\nimport type { SqlFragmentSpec } from \"@vibeorm/schema\";\nimport type { ColRef, JsonParamCell, KeyTableJoin, KeyTableMember, OrderTerm, SqlStatement, RlsReadinessStatement, RlsProbeTableStatement, RlsPolicyPathStatement, SqlExpr, TableRef } from \"./ast.ts\";\nimport type {\n AggFn,\n AggRef,\n ChainResult,\n ChainRowSource,\n ChainStatement,\n ChainStepStatement,\n DeleteStatement,\n InsertSelectStatement,\n InsertStatement,\n KeyListMember,\n KeyPage,\n KeyRows,\n OrderByColumn,\n LateralJoin,\n LeftJoin,\n CountSubquery,\n ReturningColumn,\n SelectExpr,\n SelectStatement,\n SetOperator,\n UpdateStatement,\n} from \"./ast.ts\";\nimport { CHAIN_VETO_PREFIX, CHAIN_VETO_TOKEN_PATTERN, isDbNowMarker, isExcludedRef, isJsonParamCell, isListSetOperation, isSetOperation, isSqlDefaultCell, isSqlKeepCell, isStepColumnRef } from \"./ast.ts\";\nimport type { SqlDialect } from \"./dialect.ts\";\nimport { containsPattern, endsWithPattern, startsWithPattern, strictMatchCollationPrefilter, strictMatchPattern } from \"./like.ts\";\nimport { renderAdvisoryLock, renderRowLockClause } from \"./locks.ts\";\nimport { renderDateTruncation } from \"./date-truncation.ts\";\nimport { ParamCollector } from \"./params.ts\";\nimport { isJsonListParameter, jsonListParameter } from \"./json-list-parameter.ts\";\nimport { keyListBindsUntypedRows, postgresBulkInsertArrayCast, postgresKeyListElementType } from \"./key-list.ts\";\nimport { renderRlsContext, renderRlsDisable, renderRlsDropPolicy, renderRlsEnable, renderRlsForce, renderRlsNoForce, renderRlsPolicy, renderRlsRole } from \"./dialects/postgres-rls.ts\";\n\n// ─── Result shape ─────────────────────────────────────────────────\n\nexport type RenderedQuery = {\n readonly text: string;\n readonly values: unknown[];\n /**\n * RETURNING status: \"native\" (rendered), \"omitted\" (requested but the dialect\n * lacks it — caller must re-select), \"none\" (not requested).\n */\n readonly returning: \"native\" | \"omitted\" | \"none\";\n};\n\n// ─── Entry point ──────────────────────────────────────────────────\n\nexport function renderStatement(params: { dialect: SqlDialect; statement: DiagnosticStatement | SqlStatement | RlsReadinessStatement | RlsProbeTableStatement | RlsPolicyPathStatement }): RenderedQuery {\n const { dialect, statement } = params;\n const collector = new ParamCollector(dialect);\n switch (statement.kind) {\n case \"diagnostic\": {\n // EPIC 5: `postgresExplain` wraps another statement, so it renders that\n // one first and keeps its parameters; the read-only workload reads take\n // their own identifiers and bounds. Everything else is a fixed probe.\n if (isFixedDiagnostic(statement)) return renderDiagnostic({ dialect, query: statement.query });\n if (statement.query === \"postgresExplain\") {\n return renderPostgresExplain({\n dialect,\n query: renderStatement({ dialect, statement: statement.statement }),\n ...(statement.options === undefined ? {} : { options: statement.options }),\n });\n }\n return renderPostgresWorkload({ dialect, ...statement });\n }\n case \"select\":\n return renderSelect({ dialect, statement, collector });\n case \"advisoryLock\":\n return renderAdvisoryLock({ dialect, statement, collector });\n case \"insert\":\n return renderInsert({ dialect, statement, collector });\n case \"update\":\n return renderUpdate({ dialect, statement, collector });\n case \"delete\":\n return renderDelete({ dialect, statement, collector });\n case \"chain\":\n return renderChain({ dialect, statement, collector });\n case \"rlsReadiness\": return renderRlsReadinessQuery({ dialect, ...statement });\n case \"rlsProbeTable\": return renderRlsProbeTable({ dialect, ...statement });\n case \"rlsPolicyPath\": return renderRlsPolicyPath({ dialect, ...statement });\n case \"rlsEnable\":\n return renderRlsEnable({ dialect, table: statement.table });\n case \"rlsForce\":\n return renderRlsForce({ dialect, table: statement.table });\n case \"rlsDisable\":\n return renderRlsDisable({ dialect, table: statement.table });\n case \"rlsNoForce\":\n return renderRlsNoForce({ dialect, table: statement.table });\n case \"rlsDropPolicy\":\n return renderRlsDropPolicy({ dialect, table: statement.table, policyName: statement.policyName });\n case \"rlsPolicy\":\n return renderRlsPolicy({ dialect, ...statement });\n case \"rlsContext\":\n return renderRlsContext({ dialect, ...statement });\n case \"rlsRole\":\n return renderRlsRole({ dialect, role: statement.role });\n }\n}\n\n// ─── Shared pieces ────────────────────────────────────────────────\n\nfunction quoteCol(dialect: SqlDialect, column: ColRef): string {\n const name = dialect.quoteIdent({ name: column.name });\n const ref = column.table === undefined ? name : `${dialect.quoteIdent({ name: column.table })}.${name}`;\n // groupBy date keys: the start of the period, rendered identically at the\n // projection, GROUP BY and ORDER BY sites (refused without the capability).\n if (column.truncate !== undefined) return renderDateTruncation({ dialect, reference: ref, truncation: column.truncate });\n // B4: sqlite Decimal compare/order/aggregate sites read the TEXT column as\n // REAL — the builder sets this only there, never on projections.\n if (column.castReal === true) {\n if (dialect.name !== \"sqlite\") {\n throw internalError({ message: \"ColRef.castReal is a sqlite Decimal construct\" });\n }\n return `CAST(${ref} AS REAL)`;\n }\n // D3: postgres `json` order/distinct/compare sites read the column as jsonb.\n if (column.castJsonb !== undefined) {\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: \"ColRef.castJsonb is a postgres json construct\" });\n }\n return `${ref}::${column.castJsonb}`;\n }\n return ref;\n}\n\n/**\n * An ORDER BY / DISTINCT ON column of a SELECT, protected from binding to an\n * OUTPUT column. Postgres, MySQL and SQLite all resolve a bare name in ORDER\n * BY (postgres: DISTINCT ON too) to an output column of that name FIRST. When\n * the projection renames something else to the column's name — a postgres\n * `Float[]`/`Json[]` list read as `\"col\"::text AS \"col\"`, or a projection\n * alias — the bare name would order the TEXT, not the typed column\n * (`{10}` < `{1e-07}` < `{9}`). Such a reference is qualified with the\n * select's FROM name (its alias, or the derived-table name), which only ever\n * names the input column. Qualified references, casts and truncations\n * (`castReal`, `castJsonb`, `truncate` — expressions read input columns, and a\n * truncated key must repeat its GROUP BY text) and plain projections render\n * unchanged. Window ORDER BY (ROW_NUMBER) never sees output names, so it is\n * not passed through here.\n */\nfunction typedOrderRef(params: { statement: SelectStatement; column: ColRef }): ColRef {\n const { statement, column } = params;\n if (column.table !== undefined || column.castReal === true || column.castJsonb !== undefined || column.truncate !== undefined) return column;\n const renamed = statement.columns.some(\n (projected) => (projected.alias ?? projected.name) === column.name && (projected.transform !== undefined || projected.alias !== undefined),\n );\n return renamed ? { ...column, table: statement.table.alias ?? statement.table.name } : column;\n}\n\n/**\n * The cast a {@link JsonParamCell} renders after its placeholder: the\n * dialect's json param cast (`::text::jsonb` on postgres, empty elsewhere),\n * or `::text::json` for a cell bound for a postgres `json` column — the\n * server parses the text as `json` and stores it as written (D3).\n */\nfunction jsonCellCast(dialect: SqlDialect, cell: JsonParamCell): string {\n if (cell.storage !== \"json\" || dialect.jsonParamCast === \"\") return dialect.jsonParamCast;\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: \"JsonParamCell storage json is a postgres construct\" });\n }\n return \"::text::json\";\n}\n\n/**\n * Projection rendering: a plain reference or its wire transform. JSON text\n * projections use the dialect primitive and keep explicit aliases. Text casts\n * preserve lossless transport on every dialect; both base64 forms remain\n * postgres-only.\n */\nfunction quoteProjection(dialect: SqlDialect, column: ColRef): string {\n if (column.transform === undefined) {\n const base = quoteCol(dialect, column);\n // A truncated key is an expression: it keeps the column's name as output name.\n const alias = column.alias ?? (column.truncate === undefined ? undefined : column.name);\n if (alias === undefined) return base;\n return `${base} AS ${dialect.quoteIdent({ name: alias })}`;\n }\n if (column.transform === \"jsonText\") {\n const ref = quoteCol(dialect, column);\n const alias = dialect.quoteIdent({ name: column.alias ?? column.name });\n return `${dialect.jsonTextProjection({ expression: ref })} AS ${alias}`;\n }\n const ref = quoteCol(dialect, column);\n const alias = dialect.quoteIdent({ name: column.alias ?? column.name });\n if (column.transform === \"castText\") return `${textProjection({ dialect, expression: ref })} AS ${alias}`;\n // Lane J: MySQL's lateral subselect ships Bytes as `TO_BASE64` (a newline\n // every 76 characters, which the base64 decoder skips).\n if (column.transform === \"encodeBase64\" && dialect.name === \"mysql\") return `TO_BASE64(${ref}) AS ${alias}`;\n if (dialect.name !== \"postgres\") {\n throw internalError({ message: `${column.transform} is a postgres construct` });\n }\n if (column.transform === \"encodeArrayBase64\") return `encode(array_send(${ref}), 'base64') AS ${alias}`;\n return `encode(${ref}, 'base64') AS ${alias}`;\n}\n\nfunction textProjection(params: { dialect: SqlDialect; expression: string }): string {\n return params.dialect.name === \"postgres\" ? `${params.expression}::text`\n : `CAST(${params.expression} AS ${params.dialect.name === \"mysql\" ? \"CHAR\" : \"TEXT\"})`;\n}\n\n/**\n * A SELECT list rendered exactly as a {@link SelectStatement}'s columns are —\n * plain references and their wire transforms (`\"t\".\"scores\"::text AS\n * \"scores\"`) — for SQL assembled outside the AST (extension statements), so\n * its rows reach the driver in the same formats as `findMany`'s.\n */\nexport function renderProjection(params: { dialect: SqlDialect; columns: readonly ColRef[] }): string {\n const { dialect, columns } = params;\n return columns.map((column) => quoteProjection(dialect, column)).join(\", \");\n}\n\nfunction renderTable(dialect: SqlDialect, table: TableRef): string {\n if (table.namespace !== undefined) assertSqlNamespace({ namespace: table.namespace, dialect: dialect.name });\n const relation = dialect.quoteIdent({ name: table.name });\n const name = table.namespace === undefined ? relation : `${dialect.quoteIdent({ name: table.namespace })}.${relation}`;\n if (table.alias === undefined) return name;\n return `${name} AS ${dialect.quoteIdent({ name: table.alias })}`;\n}\n\nfunction assertCount(value: number, what: string): void {\n if (!Number.isSafeInteger(value) || value < 0) {\n throw internalError({ message: `${what} must be a non-negative integer, got ${value}` });\n }\n}\n\nconst COMPARISON_SQL: Readonly<Record<string, string>> = {\n eq: \"=\",\n ne: \"<>\",\n gt: \">\",\n gte: \">=\",\n lt: \"<\",\n lte: \"<=\",\n};\n\n/**\n * Atomic SET arithmetic. `divide` is plain `/`: integer columns therefore\n * follow each dialect's own integer-division rule (pg/sqlite truncate, mysql\n * promotes to decimal) — pinned by the update-atomic-ops catalog case.\n */\nconst SET_OPERATION_SQL: Readonly<Record<SetOperator, string>> = {\n increment: \"+\",\n decrement: \"-\",\n multiply: \"*\",\n divide: \"/\",\n};\n\nconst AGG_FN_SQL: Readonly<Record<AggFn, string>> = {\n count: \"COUNT\",\n avg: \"AVG\",\n sum: \"SUM\",\n min: \"MIN\",\n max: \"MAX\",\n};\n\n/** `COUNT(*)` / `FN(\"col\")` — shared by projections, HAVING and ORDER BY. */\nfunction renderAggRef(dialect: SqlDialect, agg: AggRef): string {\n if (agg.fn === \"countAll\") return \"COUNT(*)\";\n return `${AGG_FN_SQL[agg.fn]}(${quoteCol(dialect, agg.column)})`;\n}\n\nfunction assertScalarArrays(dialect: SqlDialect, feature: string): void {\n if (dialect.capabilities.scalarArrays) return;\n throw unsupportedCapability({\n dialect: dialect.name,\n feature,\n hint: \"only postgres has native array columns — model the list as a related table instead\",\n });\n}\n\n// ─── Expressions ──────────────────────────────────────────────────\n\n/**\n * Render one boolean expression into SQL text, collecting parameters into the\n * shared collector. Public so extension delegates can AND user `where` trees\n * (compiled by the runtime) into their own statements.\n */\nexport function renderExpr(params: { dialect: SqlDialect; expr: SqlExpr; collector: ParamCollector }): string {\n const { dialect, expr, collector } = params;\n\n switch (expr.kind) {\n case \"cmp\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n // Database-clock operand: the dialect's now() expression, never a param.\n if (isDbNowMarker(expr.value)) {\n return `${quoteCol(dialect, expr.column)} ${op} ${dialect.renderDbNow({ offsetSeconds: expr.value.offsetSeconds, collector })}`;\n }\n const compared = listComparison({ dialect, column: expr.column, value: expr.value, collector });\n return `${compared.column} ${op} ${compared.operand}`;\n }\n\n case \"cmpCol\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n return `${quoteCol(dialect, expr.left)} ${op} ${quoteCol(dialect, expr.right)}`;\n }\n\n case \"isNull\":\n return `${quoteCol(dialect, expr.column)} IS ${expr.negate === true ? \"NOT NULL\" : \"NULL\"}`;\n\n case \"inArray\": {\n if (expr.values.length === 0) {\n // Empty IN matches nothing; empty NOT IN matches everything.\n return expr.negate === true ? \"1 = 1\" : \"1 = 0\";\n }\n const column = quoteCol(dialect, expr.column);\n if (expr.timeOfDay === true && dialect.timeOfDayInStrategy === \"equalities\") {\n const equalities = collector.addMany(expr.values).map((placeholder) => `${column} = ${placeholder}`);\n return `${expr.negate === true ? \"NOT \" : \"\"}(${equalities.join(\" OR \")})`;\n }\n if (dialect.inArrayStrategy === \"any\") {\n const base = `${column} = ANY(${collector.add(Array.isArray(expr.values) ? [...expr.values] : expr.values)})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n const placeholders = collector.addMany(expr.values);\n return `${column} ${expr.negate === true ? \"NOT IN\" : \"IN\"} (${placeholders.join(\", \")})`;\n }\n\n case \"tupleIn\": {\n if (expr.columns.length === 0) {\n throw internalError({ message: \"tupleIn needs at least one column\" });\n }\n for (const row of expr.rows) {\n if (row.length !== expr.columns.length) {\n throw internalError({\n message: `tupleIn row has ${row.length} values for ${expr.columns.length} columns`,\n });\n }\n }\n if (expr.rows.length === 0) {\n // Same honesty as inArray: an empty membership matches nothing.\n return expr.negate === true ? \"1 = 1\" : \"1 = 0\";\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n if (dialect.tupleInStrategy === \"rowValue\") {\n const tuples = expr.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n const base = `(${columns.join(\", \")}) IN (${tuples.join(\", \")})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n // No row constructors: an OR of COMPLETE conjunctions, never a per-column\n // IN (which would match the Cartesian product of the members).\n const conjunctions = expr.rows.map((row) => {\n const terms = row.map((value, index) => `${columns[index] as string} = ${collector.add(value)}`);\n return terms.length === 1 ? (terms[0] as string) : `(${terms.join(\" AND \")})`;\n });\n const base = conjunctions.length === 1 ? (conjunctions[0] as string) : `(${conjunctions.join(\" OR \")})`;\n return expr.negate === true ? `NOT ${base.startsWith(\"(\") ? base : `(${base})`}` : base;\n }\n\n case \"keyList\":\n return renderKeyList({ dialect, expr, collector });\n\n case \"rowCompare\": {\n // D-01: one row-value comparison; values bind in member order.\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined || expr.columns.length === 0 || expr.values.length !== expr.columns.length) {\n throw internalError({ message: `rowCompare needs a range operator and one value per column (${expr.columns.length} columns, ${expr.values.length} values)` });\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const placeholders = expr.values.map((value) => collector.add(value));\n return `(${columns.join(\", \")}) ${op} (${placeholders.join(\", \")})`;\n }\n\n case \"inSelect\": {\n // D-04: the subquery shares the collector, like EXISTS.\n if (expr.columns.length === 0) throw internalError({ message: \"inSelect needs at least one column\" });\n if (dialect.name === \"mysql\" && (expr.select.limit !== undefined || expr.select.offset !== undefined)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"LIMIT inside an IN subquery\",\n hint: \"mysql refuses LIMIT directly inside an IN subquery (error 1235); wrap the limited select in a derived table\",\n });\n }\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const tested = columns.length === 1 ? (columns[0] as string) : `(${columns.join(\", \")})`;\n const sub = renderSelect({ dialect, statement: expr.select, collector });\n return `${tested} IN (${sub.text})`;\n }\n\n case \"like\": {\n const column = quoteCol(dialect, expr.column);\n const placeholder = collector.add(expr.pattern);\n let base: string;\n if (expr.insensitive === true) {\n base =\n dialect.insensitiveLike === \"ilike\"\n ? `${column} ILIKE ${placeholder}`\n : expr.ciCollation === true\n ? // #36: the column's declared `_ci` collation already folds case —\n // plain LIKE keeps the index usable.\n `${column} LIKE ${placeholder}`\n : `LOWER(${column}) LIKE LOWER(${placeholder})`;\n } else {\n base = `${column} LIKE ${placeholder}`;\n }\n if (dialect.likeEscapeClause !== null) {\n base = `${base}${dialect.likeEscapeClause}`;\n }\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"strictMatch\": {\n const column = quoteCol(dialect, expr.column);\n let base: string;\n if (expr.op === \"equals\") {\n // pg and sqlite `=` are already byte-exact; only mysql's `_ci`\n // collations fold equality and need the BINARY cast.\n base =\n dialect.strictMatchStrategy === \"binary\"\n ? `${column} = CAST(${collector.add(expr.value)} AS BINARY)`\n : `${column} = ${collector.add(expr.value)}`;\n } else {\n const pattern = strictMatchPattern({\n strategy: dialect.strictMatchStrategy,\n op: expr.op,\n value: expr.value,\n });\n if (dialect.strictMatchStrategy === \"glob\") {\n base = `${column} GLOB ${collector.add(pattern)}`;\n } else {\n // Fix lane Q2 (D-06): mysql strict startsWith ANDs the collation\n // LIKE first (same pattern, bound first) — an index-boundable\n // superset of the byte-exact test, so the rows are unchanged.\n const prefilter = strictMatchCollationPrefilter({\n strategy: dialect.strictMatchStrategy,\n op: expr.op,\n negate: expr.negate === true,\n })\n ? `${column} LIKE ${collector.add(pattern)}${dialect.likeEscapeClause ?? \"\"}`\n : null;\n const placeholder = collector.add(pattern);\n base =\n dialect.strictMatchStrategy === \"binary\"\n ? `${column} LIKE CAST(${placeholder} AS BINARY)`\n : `${column} LIKE ${placeholder}`;\n if (dialect.likeEscapeClause !== null) base = `${base}${dialect.likeEscapeClause}`;\n if (prefilter !== null) base = `(${prefilter} AND ${base})`;\n }\n }\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"and\":\n case \"or\": {\n if (expr.operands.length === 0) {\n // Neutral elements: empty AND is always-true, empty OR always-false.\n return expr.kind === \"and\" ? \"1 = 1\" : \"1 = 0\";\n }\n if (expr.operands.length === 1) {\n return renderExpr({ dialect, expr: expr.operands[0]!, collector });\n }\n const joiner = expr.kind === \"and\" ? \" AND \" : \" OR \";\n const rendered = expr.operands.map((operand) => renderExpr({ dialect, expr: operand, collector }));\n return `(${rendered.join(joiner)})`;\n }\n\n case \"not\":\n return `NOT (${renderExpr({ dialect, expr: expr.operand, collector })})`;\n\n case \"aggCmp\": {\n const op = COMPARISON_SQL[expr.op];\n if (op === undefined) {\n throw internalError({ message: `unknown comparison operator \"${expr.op}\"` });\n }\n return `${renderAggRef(dialect, expr.agg)} ${op} ${collector.add(expr.value)}`;\n }\n\n case \"arrayHas\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"has\\\"\");\n const compared = listComparison({ dialect, column: expr.column, value: expr.value, collector });\n const base = `${compared.operand} = ANY(${compared.column})`;\n return expr.negate === true ? `NOT (${base})` : base;\n }\n\n case \"arrayContainsAll\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"hasEvery\\\"\");\n const values = Array.isArray(expr.values) ? [...expr.values] : expr.values;\n const compared = listComparison({ dialect, column: expr.column, value: values, collector });\n return `${compared.column} @> ${compared.operand}`;\n }\n\n case \"arrayOverlaps\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"hasSome\\\"\");\n const values = Array.isArray(expr.values) ? [...expr.values] : expr.values;\n const compared = listComparison({ dialect, column: expr.column, value: values, collector });\n return `${compared.column} && ${compared.operand}`;\n }\n\n case \"arrayIsEmpty\": {\n assertScalarArrays(dialect, \"the scalar-list filter \\\"isEmpty\\\"\");\n // v1 semantics kept: array_length of NULL and of '{}' are both NULL, so\n // `isEmpty: true` matches NULL **and** empty lists.\n const column = quoteCol(dialect, expr.column);\n return `array_length(${column}, 1) IS ${expr.empty ? \"NULL\" : \"NOT NULL\"}`;\n }\n\n case \"jsonFilter\":\n return renderJsonFilter({ dialect, expr, collector });\n\n case \"exists\": {\n // The subquery shares the statement's collector, so its parameters land\n // in the single sequence exactly where they appear in the text.\n const sub = renderSelect({ dialect, statement: expr.select, collector });\n return `${expr.negate === true ? \"NOT \" : \"\"}EXISTS (${sub.text})`;\n }\n\n case \"composed\":\n return `(${renderSqlFragment({ dialect, fragment: expr.fragment, collector })})`;\n\n case \"fragment\":\n return renderFragment({ dialect, fragment: expr.fragment, collector });\n\n case \"raw\":\n return expr.text;\n }\n}\n\n// ─── Bound fragments (extension SQL plane) ───────────────────\n\n/**\n * Render a neutral bound fragment (extensions.md §3): literal text verbatim,\n * `{ param }` through the collector (single placeholder sequence), `{ ident }`\n * paths through dialect.quoteIdent. Exported so extension delegates can build\n * full statements sharing one collector with core-compiled WHERE trees.\n */\nexport function renderFragment(params: {\n dialect: SqlDialect;\n fragment: SqlFragmentSpec;\n collector: ParamCollector;\n}): string {\n const { dialect, fragment, collector } = params;\n let text = \"\";\n for (const part of fragment.parts) {\n if (typeof part === \"string\") {\n text += part;\n } else if (\"param\" in part) {\n text += collector.add(part.param);\n } else {\n text += part.ident.map((name) => dialect.quoteIdent({ name })).join(\".\");\n }\n }\n return text;\n}\n\n// ─── JSON path filters ─────────────────────────────────────────────\n\n/** `$.a.b[0]` path string for sqlite/mysql — always bound, never spliced. */\nfunction jsonPathString(path: readonly (string | number)[]): string {\n let out = \"$\";\n for (const segment of path) {\n if (typeof segment === \"number\") {\n out += `[${segment}]`;\n } else if (/^[A-Za-z_][A-Za-z0-9_]*$/.test(segment)) {\n out += `.${segment}`;\n } else {\n // A quoted key uses JSON-string escaping in both engines' path syntax:\n // the backslash FIRST, or a key containing one silently matches nothing.\n out += `.\"${segment.replaceAll(\"\\\\\", \"\\\\\\\\\").replaceAll('\"', '\\\\\"')}\"`;\n }\n }\n return out;\n}\n\n/**\n * Column and operand of a comparison (`cmp`, `has`, `hasEvery`, `hasSome`).\n * A Json-list operand of a `json[]` column (`Json[] @db.Json`) compares as\n * jsonb on both sides — `\"col\"::jsonb[]` against `$n::text::jsonb[]` (or\n * `$n::text::jsonb` for one element) — because `json` has no equality\n * operator at all (\"could not identify an equality operator for type json\").\n * Write sites (`push`) keep the `json` operand. Everything else renders as\n * before. The column side is added first only in text: it binds nothing.\n */\nfunction listComparison(params: {\n dialect: SqlDialect;\n column: ColRef;\n value: unknown;\n collector: ParamCollector;\n}): { readonly column: string; readonly operand: string } {\n const { dialect, column, value, collector } = params;\n if (isJsonListParameter(value) && value.storage === \"json\") {\n return {\n column: `${quoteCol(dialect, column)}::jsonb[]`,\n operand: collector.add(jsonListParameter({ value: value.value, storage: \"jsonb\" })),\n };\n }\n return { column: quoteCol(dialect, column), operand: collector.add(value) };\n}\n\ntype KeyListExpr = Extract<SqlExpr, { kind: \"keyList\" }>;\n\n/**\n * Key-list membership per `SqlDialect.keyListStrategy` (see the `keyList`\n * node): postgres binds one typed array per member and unnests them in a\n * semi-join subquery — except when a member is a `DateTime` without a\n * declared native type ({@link keyListBindsUntypedRows}): then it renders the\n * row-constructor list of untyped parameters, so each member is typed from\n * its column like `\"col\" = $n`; mysql renders the row-constructor list (an OR\n * of complete conjunctions when a member is a time of day and the dialect\n * declares `equalities` for it); sqlite renders `IN (VALUES …)`.\n */\nfunction renderKeyList(params: { dialect: SqlDialect; expr: KeyListExpr; collector: ParamCollector }): string {\n const { dialect, expr, collector } = params;\n const arity = expr.columns.length;\n if (arity === 0) throw internalError({ message: \"keyList needs at least one column\" });\n if (expr.members.length !== arity) {\n throw internalError({ message: `keyList has ${expr.members.length} members for ${arity} columns` });\n }\n for (const row of expr.rows) {\n if (row.length !== arity) throw internalError({ message: `keyList row has ${row.length} values for ${arity} columns` });\n }\n // Same honesty as inArray: an empty key list matches nothing.\n if (expr.rows.length === 0) return \"1 = 0\";\n const columns = expr.columns.map((column) => quoteCol(dialect, column));\n const tuple = arity === 1 ? (columns[0] as string) : `(${columns.join(\", \")})`;\n if (dialect.keyListStrategy === \"unnest\") {\n // Every member's element type first: a member without one (Json, an\n // unknown native type) is refused in either form.\n const types = expr.members.map((member) => postgresKeyListElementType({ dialect, member }));\n if (!keyListBindsUntypedRows({ members: expr.members })) {\n const arrays = types.map((type, index) => `${collector.add(expr.rows.map((row) => row[index]))}::${type}[]`);\n return `${tuple} IN (SELECT * FROM unnest(${arrays.join(\", \")}))`;\n }\n }\n if (dialect.timeOfDayInStrategy === \"equalities\" && expr.members.some((member) => member.timeOfDay === true)) {\n const conjunctions = expr.rows.map((row) => {\n const terms = row.map((value, index) => `${columns[index] as string} = ${collector.add(value)}`);\n return terms.length === 1 ? (terms[0] as string) : `(${terms.join(\" AND \")})`;\n });\n return conjunctions.length === 1 ? (conjunctions[0] as string) : `(${conjunctions.join(\" OR \")})`;\n }\n const tuples = expr.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n return dialect.keyListStrategy === \"values\"\n ? `${tuple} IN (VALUES ${tuples.join(\", \")})`\n : `${tuple} IN (${tuples.join(\", \")})`;\n}\n\n// ─── Fix lane Q1 (round 3, DB-01): per-key page ─────────────────────────\n\n/** Key-list source alias of a per-key page; its members are `__vibe_k<i>` on postgres. */\nconst KEY_PAGE_KEYS = \"__vibe_keys\";\n/** Postgres: the lateral page of identity keys. */\nconst KEY_PAGE_IDS = \"__vibe_ids\";\n/** The child table re-read by identity. */\nconst KEY_PAGE_ROWS = \"__vibe_page\";\n\n/** Members of a {@link KeyPage}'s `select` the per-key page renders; any other is a malformed node. */\nconst KEY_PAGE_SELECT_MEMBERS: ReadonlySet<string> = new Set([\"kind\", \"table\", \"columns\", \"where\", \"orderBy\", \"limit\", \"offset\"]);\n\n/**\n * The per-key page (`SelectStatement.keyPage`) per `SqlDialect.keyPageStrategy`\n * — see {@link KeyPage}. Parameters join the shared sequence in text order:\n * the key tuples (FROM), then the page's own `where`.\n */\nfunction renderKeyPage(params: { dialect: SqlDialect; page: KeyPage; collector: ParamCollector }): string {\n const { dialect, page, collector } = params;\n const { select } = page;\n const arity = page.keyColumns.length;\n if (arity === 0 || page.members.length !== arity) {\n throw internalError({ message: `keyPage has ${page.members.length} members for ${arity} key columns` });\n }\n if (page.rows.length === 0) throw internalError({ message: \"keyPage needs at least one key\" });\n for (const row of page.rows) {\n if (row.length !== arity) throw internalError({ message: `keyPage row has ${row.length} values for ${arity} key columns` });\n }\n if (page.identity.length === 0) throw internalError({ message: \"keyPage needs the child's identity columns\" });\n const order = select.orderBy ?? [];\n if (order.length === 0 || order.some((term) => !(\"column\" in term))) {\n throw internalError({ message: \"keyPage needs a non-empty order of plain column terms\" });\n }\n if (select.table.alias !== undefined || Object.keys(select).some((member) => !KEY_PAGE_SELECT_MEMBERS.has(member))) {\n throw internalError({ message: \"keyPage select carries a member the per-key page cannot render\" });\n }\n if (dialect.keyPageStrategy === \"window\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a per-key page (keyPage)\",\n hint: \"the runtime keeps the ROW_NUMBER window on this dialect\",\n });\n }\n const pageRef = (column: ColRef): ColRef => ({ ...column, table: KEY_PAGE_ROWS });\n const projection = select.columns.map((column) => quoteProjection(dialect, pageRef(column)));\n const withKey = (keyRef: (index: number) => ColRef): SqlExpr => {\n const equalities: SqlExpr[] = page.keyColumns.map((column, index) => ({ kind: \"cmpCol\", op: \"eq\", left: column, right: keyRef(index) }));\n const operands = select.where === undefined ? equalities : [...equalities, select.where];\n return operands.length === 1 ? (operands[0] as SqlExpr) : { kind: \"and\", operands };\n };\n const keyPage = (where: SqlExpr, rank: boolean): SelectStatement => ({\n kind: \"select\",\n table: select.table,\n columns: page.identity,\n ...(rank ? { rowNumber: { partitionBy: page.keyColumns, orderBy: order, alias: page.rankAlias } } : {}),\n where,\n orderBy: order,\n ...(select.limit === undefined ? {} : { limit: select.limit }),\n ...(select.offset === undefined ? {} : { offset: select.offset }),\n });\n const rows = renderTable(dialect, { ...select.table, alias: KEY_PAGE_ROWS });\n const keyAlias = select.table.name === KEY_PAGE_KEYS ? `${KEY_PAGE_KEYS}_1` : KEY_PAGE_KEYS;\n const keys = dialect.quoteIdent({ name: keyAlias });\n\n if (dialect.keyPageStrategy === \"lateral\") {\n // One typed array per member, exactly the key-list filter's element types.\n if (keyListBindsUntypedRows({ members: page.members })) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a per-key page over a DateTime key without a declared native type\",\n hint: \"the runtime keeps the ROW_NUMBER window for such keys\",\n });\n }\n const types = page.members.map((member) => postgresKeyListElementType({ dialect, member }));\n const arrays = types.map((type, index) => `${collector.add(page.rows.map((row) => row[index]))}::${type}[]`);\n const names = page.keyColumns.map((_, index) => dialect.quoteIdent({ name: `__vibe_k${index}` }));\n const ids = renderSelect({ dialect, statement: keyPage(withKey((index) => ({ table: keyAlias, name: `__vibe_k${index}` })), true), collector });\n const on = page.identity.map((column) => `${quoteCol(dialect, pageRef(column))} = ${quoteCol(dialect, { table: KEY_PAGE_IDS, name: column.name })}`).join(\" AND \");\n const rank = quoteCol(dialect, { table: KEY_PAGE_IDS, name: page.rankAlias });\n return `SELECT ${[...projection, rank].join(\", \")} FROM unnest(${arrays.join(\", \")}) AS ${keys} (${names.join(\", \")}) CROSS JOIN LATERAL (${ids.text}) AS ${dialect.quoteIdent({ name: KEY_PAGE_IDS })} INNER JOIN ${rows} ON ${on}`;\n }\n\n // inLimit: the rank is re-derived over the fetched page — rendered first,\n // it is text order; plain column terms bind nothing.\n const partition = page.keyColumns.map((column) => quoteCol(dialect, pageRef(column))).join(\", \");\n const rankOrder = order.map((term) => renderOrderTerm({ dialect, term: { ...term, column: pageRef((term as OrderByColumn).column) }, collector })).join(\", \");\n const rank = `ROW_NUMBER() OVER (PARTITION BY ${partition} ORDER BY ${rankOrder}) AS ${dialect.quoteIdent({ name: page.rankAlias })}`;\n const tuples = page.rows.map((row) => `(${collector.addMany(row).join(\", \")})`);\n // SQLite names a VALUES clause's columns column1, column2, … (documented).\n const membership = renderExpr({\n dialect,\n expr: { kind: \"inSelect\", columns: page.identity.map(pageRef), select: keyPage(withKey((index) => ({ table: keyAlias, name: `column${index + 1}` })), false) },\n collector,\n });\n return `SELECT ${[...projection, rank].join(\", \")} FROM (VALUES ${tuples.join(\", \")}) AS ${keys} INNER JOIN ${rows} ON ${membership}`;\n}\n\n// ─── Statement-count pass EPIC 4 (ST-07): key rows ───\n\n/**\n * The derived table of `SelectStatement.fromKeys` (see {@link KeyRows}):\n * `unnest($1::<type>[], …) AS \"<name>\" (\"<column>\", …)` — one typed array per\n * column, bound at the FROM position of the shared parameter sequence.\n *\n * @throws VibeError `VIBE_UNSUPPORTED_CAPABILITY` on a dialect without the\n * typed-array key list (`keyListStrategy` other than `unnest`), for a\n * `DateTime` member without a declared native type, and for a member type\n * the key list does not know.\n */\nfunction renderKeyRows(params: { dialect: SqlDialect; statement: SelectStatement; keys: KeyRows; collector: ParamCollector }): string {\n const { dialect, statement, keys, collector } = params;\n if (statement.fromSelect !== undefined || statement.keyPage !== undefined || statement.fromUnion !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"fromKeys uses table.name as the derived-table alias — fromSelect, keyPage, fromUnion and table.alias must be unset\" });\n }\n // A lock over bound key rows would lock nothing.\n if (statement.rowLock !== undefined) throw internalError({ message: \"a locking read cannot read from key rows\" });\n const arity = keys.columns.length;\n if (arity === 0 || keys.members.length !== arity) {\n throw internalError({ message: `fromKeys has ${keys.members.length} members for ${arity} columns` });\n }\n if (keys.rows.length === 0) throw internalError({ message: \"fromKeys needs at least one key row\" });\n for (const row of keys.rows) {\n if (row.length !== arity) throw internalError({ message: `fromKeys row has ${row.length} values for ${arity} columns` });\n }\n if (dialect.keyListStrategy !== \"unnest\" || keyListBindsUntypedRows({ members: keys.members })) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: dialect.keyListStrategy !== \"unnest\" ? \"a key-rows FROM (fromKeys)\" : \"a key-rows FROM over a DateTime key without a declared native type\",\n hint: \"the runtime keeps the per-relation loads for this write\",\n });\n }\n const types = keys.members.map((member) => postgresKeyListElementType({ dialect, member }));\n const arrays = types.map((type, index) => `${collector.add(keys.rows.map((row) => row[index]))}::${type}[]`);\n const names = keys.columns.map((name) => dialect.quoteIdent({ name }));\n return `unnest(${arrays.join(\", \")}) AS ${dialect.quoteIdent({ name: statement.table.name })} (${names.join(\", \")})`;\n}\n\n// ─── Fix lane Q2 (round 3, DB-07): union page ───\n\n/** Members a {@link SelectStatement.fromUnion} branch may carry; any other is a malformed node. */\nconst UNION_BRANCH_MEMBERS: ReadonlySet<string> = new Set([\"kind\", \"table\", \"columns\", \"where\", \"orderBy\", \"limit\"]);\n\n/**\n * The `UNION ALL` of a union page (`SelectStatement.fromUnion`), each branch\n * in its own derived table `\"__vibe_u<i>\"` — see the field's docs. Branches\n * render (and bind) in order.\n */\nfunction renderUnionPage(params: { dialect: SqlDialect; statement: SelectStatement; collector: ParamCollector }): string {\n const { dialect, statement, collector } = params;\n const branches = statement.fromUnion ?? [];\n if (branches.length < 2) throw internalError({ message: \"fromUnion needs at least two branches\" });\n if (statement.fromSelect !== undefined || statement.keyPage !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"fromUnion uses table.name as the derived-table alias — fromSelect, keyPage and table.alias must be unset\" });\n }\n // A lock over a derived union would not lock the base rows the branches read.\n if (statement.rowLock !== undefined) throw internalError({ message: \"a locking read cannot read from a union page\" });\n const outputNames = (branch: SelectStatement): string => branch.columns.map((column) => column.alias ?? column.name).join(\"\\u0000\");\n const names = outputNames(branches[0] as SelectStatement);\n return branches\n .map((branch, index) => {\n if (branch.columns.length === 0 || Object.keys(branch).some((member) => !UNION_BRANCH_MEMBERS.has(member))) {\n throw internalError({ message: \"a fromUnion branch must be a plain SELECT <columns> FROM <table> [WHERE] [ORDER BY] [LIMIT]\" });\n }\n if (outputNames(branch) !== names) throw internalError({ message: \"fromUnion branches must project the same output names in the same order\" });\n const inner = renderSelect({ dialect, statement: branch, collector });\n return `SELECT * FROM (${inner.text}) AS ${dialect.quoteIdent({ name: `__vibe_u${index}` })}`;\n })\n .join(\" UNION ALL \");\n}\n\ntype JsonFilterExpr = Extract<SqlExpr, { kind: \"jsonFilter\" }>;\n\nfunction jsonStringPattern(params: { expr: JsonFilterExpr }): string {\n const { expr } = params;\n if (typeof expr.value !== \"string\") {\n throw internalError({ message: `json ${expr.op} expects a string operand` });\n }\n if (expr.op === \"string_contains\") return containsPattern({ raw: expr.value });\n if (expr.op === \"string_starts_with\") return startsWithPattern({ raw: expr.value });\n return endsWithPattern({ raw: expr.value });\n}\n\n/** Case-[in]sensitive LIKE over an extracted-text expression, per dialect. */\nfunction renderJsonLike(params: {\n dialect: SqlDialect;\n target: string;\n expr: JsonFilterExpr;\n collector: ParamCollector;\n}): string {\n const { dialect, target, expr, collector } = params;\n const placeholder = collector.add(jsonStringPattern({ expr }));\n let base: string;\n if (expr.insensitive === true) {\n base =\n dialect.insensitiveLike === \"ilike\"\n ? `${target} ILIKE ${placeholder}`\n : `LOWER(${target}) LIKE LOWER(${placeholder})`;\n } else {\n base = `${target} LIKE ${placeholder}`;\n }\n if (dialect.likeEscapeClause !== null) base = `${base}${dialect.likeEscapeClause}`;\n return expr.negate === true ? `NOT (${base})` : base;\n}\n\n/**\n * One JSON path predicate, per dialect strategy. The path is BOUND: a `text[]`\n * parameter on postgres (cast so string-literal array forms work too), a\n * `$.a.b` path string elsewhere. Values bind as JSON text for json/jsonb\n * comparisons and as LIKE patterns for the string ops.\n */\nfunction renderJsonFilter(params: {\n dialect: SqlDialect;\n expr: JsonFilterExpr;\n collector: ParamCollector;\n}): string {\n const { dialect, expr, collector } = params;\n if (!dialect.supportedJsonOps.includes(expr.op)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: `the json filter \"${expr.op}\"`,\n hint: `this dialect can express: ${dialect.supportedJsonOps.join(\", \")}`,\n });\n }\n const cmp = expr.negate === true ? \"<>\" : \"=\";\n\n if (dialect.jsonPathMode === \"operators\") {\n const column = quoteCol(dialect, expr.column);\n const pathParam = `${collector.add(expr.path.map(String))}::text[]`;\n // A `json` column (`Json @db.Json`) has no `=`, `<>` or `@>` — postgres\n // defines them for jsonb only (SQLSTATE 42883 `json = jsonb`). The\n // value-comparing ops cast the EXTRACTED value, not the column: the\n // result is jsonb equality and containment, a jsonb column's semantics\n // (json navigation also takes the LAST of duplicate keys), and only the\n // sub-value is converted — ~40% faster than casting the whole document\n // on 20,000 4-KB rows (PostgreSQL 18.6). The string ops read the same\n // jsonb value as text (`#>> '{}'`): json's own `#>>` returns the STORED\n // spelling of a non-string value (`1e2`, `[1, 2]`, both duplicate keys)\n // where a jsonb column reads `100`, `[1, 2]` and the last key. For a\n // string value both forms return the same unescaped text.\n const extracted = expr.storage === \"json\" ? `(${column} #> ${pathParam})::jsonb` : `(${column} #> ${pathParam})`;\n switch (expr.op) {\n case \"equals\":\n return `${extracted} ${cmp} ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = expr.storage === \"json\" ? `(${extracted} #>> '{}')` : `(${column} #>> ${pathParam})`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_contains\":\n return `${extracted} @> ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"array_starts_with\":\n return `${extracted} -> 0 = ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n case \"array_ends_with\":\n return `${extracted} -> -1 = ${collector.add(JSON.stringify(expr.value))}${dialect.jsonParamCast}`;\n }\n }\n\n if (dialect.jsonPathMode === \"sqliteExtract\") {\n const column = quoteCol(dialect, expr.column);\n // JSON booleans surface as SQL 0/1, so value equality alone loses type.\n const typeMatches = (type: string, value: unknown): string => {\n if (typeof value === \"number\") return `${type} IN ('integer', 'real')`;\n const tag = typeof value === \"boolean\" ? String(value)\n : value === null ? \"null\" : Array.isArray(value) ? \"array\"\n : typeof value === \"object\" ? \"object\" : \"text\";\n return `${type} = '${tag}'`;\n };\n const compareExtracted = (path: string, value: unknown): string => {\n const type = `json_type(${column}, ${collector.add(path)})`;\n const guard = typeMatches(type, value);\n let base = guard;\n if (value !== null) {\n const target = `json_extract(${column}, ${collector.add(path)})`;\n const bound = typeof value === \"boolean\" ? (value ? 1 : 0) : value;\n const comparison = typeof value === \"object\"\n ? renderSqliteJsonEquality({ dialect, left: target, right: collector.add(JSON.stringify(value)) })\n : `${target} = ${collector.add(bound)}`;\n base = `(${guard} AND ${comparison})`;\n }\n return expr.negate === true ? `NOT (${base})` : base;\n };\n switch (expr.op) {\n case \"equals\":\n return compareExtracted(jsonPathString(expr.path), expr.value);\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = `json_extract(${column}, ${collector.add(jsonPathString(expr.path))})`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_starts_with\":\n case \"array_ends_with\": {\n // Edge-element access: `$[0]` / `$[#-1]` path elements (sqlite ≥3.31;\n // bun:sqlite bundles far newer) — N6/board #21.\n const edge = expr.op === \"array_starts_with\" ? \"[0]\" : \"[#-1]\";\n return compareExtracted(`${jsonPathString(expr.path)}${edge}`, expr.value);\n }\n case \"array_contains\": {\n // Scalar-needle containment via json_each() EXISTS — one EXISTS per\n // element, ANDed (jsonb `@>` semantics for scalar members). Deep\n // structural containment (object/array members) has no cheap faithful\n // sqlite form and stays refused; JSON null members compare through\n // json_each's 'null' type tag, not SQL NULL, so they are refused too.\n //\n // Haystack type guard (wave-C review): json_each() over a path holding\n // a SCALAR yields one row carrying that scalar, so an unguarded EXISTS\n // matched `{ tags: \"a\" }` against needle `[\"a\"]` where postgres (`@>`\n // with an array needle) and mysql (JSON_CONTAINS against an array\n // literal) are false. json_type() is NULL for a missing path, so\n // missing paths and NULL columns stay non-matches — and an empty\n // needle reduces to the guard alone: contained in every ARRAY (pg's\n // `@> '[]'` truth) and in nothing else.\n const guard = `json_type(${column}, ${collector.add(jsonPathString(expr.path))}) = 'array'`;\n const elements = Array.isArray(expr.value) ? expr.value : [expr.value];\n const tests = elements.map((element) => {\n if (element === null || (typeof element === \"object\" && element !== null)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"json array_contains with object/array/null elements\",\n hint: \"sqlite expresses scalar-element containment only — deep structural containment needs postgres or mysql\",\n });\n }\n const bound = typeof element === \"boolean\" ? (element ? 1 : 0) : element;\n const path = collector.add(jsonPathString(expr.path));\n const type = `${dialect.quoteIdent({ name: \"json_each\" })}.${dialect.quoteIdent({ name: \"type\" })}`;\n return `EXISTS (SELECT 1 FROM json_each(${column}, ${path}) WHERE ${typeMatches(type, element)} AND ${dialect.quoteIdent({ name: \"json_each\" })}.${dialect.quoteIdent({ name: \"value\" })} = ${collector.add(bound)})`;\n });\n return tests.length === 0 ? guard : `(${[guard, ...tests].join(\" AND \")})`;\n }\n default:\n throw internalError({ message: `json op \"${expr.op}\" leaked past supportedJsonOps on sqlite` });\n }\n }\n\n // mysqlExtract\n const column = quoteCol(dialect, expr.column);\n const pathString = jsonPathString(expr.path);\n switch (expr.op) {\n case \"equals\":\n return `JSON_EXTRACT(${column}, ${collector.add(pathString)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n case \"string_contains\":\n case \"string_starts_with\":\n case \"string_ends_with\": {\n const target = `JSON_UNQUOTE(JSON_EXTRACT(${column}, ${collector.add(pathString)}))`;\n return renderJsonLike({ dialect, target, expr, collector });\n }\n case \"array_contains\":\n return `JSON_CONTAINS(JSON_EXTRACT(${column}, ${collector.add(pathString)}), CAST(${collector.add(JSON.stringify(expr.value))} AS JSON))`;\n case \"array_starts_with\":\n return `JSON_EXTRACT(${column}, ${collector.add(`${pathString}[0]`)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n case \"array_ends_with\":\n return `JSON_EXTRACT(${column}, ${collector.add(`${pathString}[last]`)}) ${cmp} CAST(${collector.add(JSON.stringify(expr.value))} AS JSON)`;\n }\n}\n\n// ─── Ordering ─────────────────────────────────────────────────────\n\nfunction renderOrderTerm(params: { dialect: SqlDialect; term: OrderTerm; collector: ParamCollector }): string {\n const { dialect, term, collector } = params;\n if (\"agg\" in term) {\n return `${renderAggRef(dialect, term.agg)} ${term.direction === \"asc\" ? \"ASC\" : \"DESC\"}`;\n }\n if (\"select\" in term) {\n // Relation orderBy: a correlated scalar subquery — its parameters merge\n // into the shared sequence exactly where they appear in the text.\n const sub = renderSelect({ dialect, statement: term.select, collector });\n return `(${sub.text}) ${term.direction === \"asc\" ? \"ASC\" : \"DESC\"}`;\n }\n const column = quoteCol(dialect, term.column);\n const direction = term.direction === \"asc\" ? \"ASC\" : \"DESC\";\n if (term.nulls === undefined) {\n return `${column} ${direction}`;\n }\n if (dialect.orderByNullsMode === \"native\") {\n return `${column} ${direction} NULLS ${term.nulls === \"first\" ? \"FIRST\" : \"LAST\"}`;\n }\n // Emulation (mysql): the engine's native order already places NULLs FIRST on\n // ASC and LAST on DESC — those pairings render the bare term (the redundant\n // boolean pre-term cost a per-row evaluation and could defeat index-order\n // scans, #14). Only the diverging pairings need the `IS NULL` pre-term:\n // false(0) sorts first, so plain `IS NULL` pushes nulls last and\n // `IS NULL DESC` pulls them first.\n if ((term.nulls === \"first\") === (term.direction === \"asc\")) {\n return `${column} ${direction}`;\n }\n const nullsTerm = term.nulls === \"first\" ? `${column} IS NULL DESC` : `${column} IS NULL`;\n return `${nullsTerm}, ${column} ${direction}`;\n}\n\n// ─── Projections ──────────────────────────────────────────────────\n\nfunction renderSelectExpr(params: { dialect: SqlDialect; expr: SelectExpr }): string {\n const { dialect, expr } = params;\n if (expr.kind === \"one\") return \"1\";\n const alias = expr.alias === undefined ? \"\" : ` AS ${dialect.quoteIdent({ name: expr.alias })}`;\n return `COUNT(*)${alias}`;\n}\n\n// ─── Lateral JSON joins ───────────────────────────────────\n\n/**\n * `LEFT JOIN LATERAL (… to_json …) AS alias ON true`. Postgres SQL, and MySQL\n * 8.0.14+ through `SqlDialect.lateralJson` (lane J: `JSON_ARRAY` rows,\n * `JSON_ARRAYAGG`, an ordered level's `ROW_NUMBER()` position slot) — the\n * runtime gates the \"join\" strategy on `capabilities.lateralJoin` at build\n * time, and this renderer refuses too (dialect honesty, rule 4).\n *\n * `json`, not `jsonb`: the payload is transport — parsed by the driver and\n * never touched by a JSON operator on the server. `jsonb_agg(to_jsonb(…))`\n * builds postgres's binary JSON (sorted, de-duplicated keys) and then\n * serializes it straight back to text for the wire, which measured at 2–3.7×\n * the server time of `json_agg(to_json(…))` for identical decoded values\n * (`.ai/plans/26.09.08 - performance-join-strategy.md` §1.2). The observable\n * differences are textual only: `json` keeps construction key order and `-0`,\n * `jsonb` normalizes both; every scalar still rides the B3 transforms.\n */\nfunction renderPositionalRow(params: { dialect: SqlDialect; join: LateralJoin; subAlias: string }): string {\n const { dialect, join, subAlias } = params;\n const json = lateralJsonOf({ dialect });\n // Lane J: a `positionSlot` dialect's ordered list level carries its\n // ROW_NUMBER() position as the LAST slot (the runtime sorts by it).\n const position = join.select.rowNumber;\n const positioned = position !== undefined && json.order === \"positionSlot\" && join.agg === \"jsonArray\" &&\n position.partitionBy.length === 0 && position.orderBy.length > 0;\n if (join.select.columns.length === 0 || join.select.selectExpr !== undefined ||\n (join.select.aggregates?.length ?? 0) > 0 || (position !== undefined && !positioned)) {\n throw internalError({ message: \"positional lateral rows require an explicit column-only projection\" });\n }\n const names = [...join.select.columns.map((column) => projectionOutputName({ column })), ...(positioned ? [position.alias] : [])];\n if (new Set(names).size !== names.length) {\n throw internalError({ message: \"positional lateral projection has duplicate output names\" });\n }\n const values = names.map((name) => `${subAlias}.${dialect.quoteIdent({ name })}`);\n const chunks: string[] = [];\n for (let index = 0; index < values.length; index += JSON_TRANSPORT.chunkSize) {\n chunks.push(`${json.rowArray}(${values.slice(index, index + JSON_TRANSPORT.chunkSize).join(\", \")})`);\n }\n if (chunks.length > JSON_TRANSPORT.chunkSize) {\n throw internalError({ message: \"positional lateral projection exceeds the transport width limit\" });\n }\n return chunks.length === 1 ? chunks[0] as string : `${json.rowArray}(${chunks.join(\", \")})`;\n}\n\n/** The dialect's lateral JSON functions; callers already refused a dialect without them. */\nfunction lateralJsonOf(params: { dialect: SqlDialect }): NonNullable<SqlDialect[\"lateralJson\"]> {\n const json = params.dialect.lateralJson;\n if (json === null) throw internalError({ message: \"lateral JSON rendering on a dialect without LATERAL\" });\n return json;\n}\n\nfunction renderLateralJoin(params: {\n dialect: SqlDialect;\n join: LateralJoin;\n collector: ParamCollector;\n}): string {\n const { dialect, join, collector } = params;\n const inner = renderSelect({ dialect, statement: join.select, collector });\n if (join.agg === \"count\") {\n if (join.rowFormat === \"positional\" || join.select.columns.length !== 0 ||\n join.select.selectExpr?.kind !== \"countAll\" || join.select.selectExpr.alias !== join.columnAlias ||\n join.select.groupBy !== undefined || join.select.having !== undefined ||\n join.select.limit !== undefined || join.select.offset !== undefined || join.select.distinctOn !== undefined ||\n join.select.distinct !== undefined) {\n throw internalError({ message: \"count lateral must return one ungrouped COUNT(*) under its column alias\" });\n }\n return `LEFT JOIN LATERAL (${inner.text}) AS ${dialect.quoteIdent({ name: join.alias })} ON true`;\n }\n const columnAlias = dialect.quoteIdent({ name: join.columnAlias });\n const subAlias = dialect.quoteIdent({ name: \"__sub\" });\n const json = lateralJsonOf({ dialect });\n // N2 (SQL review): json_agg over a subquery only \"usually\" preserves the\n // subquery's order — pin it with an explicit ORDER BY inside the aggregate\n // (the subquery keeps its own ORDER BY for LIMIT). Only column terms that\n // are PROJECTED (and untransformed — a B3 ::text cast would re-sort\n // lexicographically) can be referenced through `__sub`; anything else keeps\n // the old behavior. A `positionSlot` dialect (MySQL) orders through the\n // position slot instead ({@link renderPositionalRow}).\n let aggOrder = \"\";\n if (json.order === \"inAggregate\" && join.agg === \"jsonArray\" && join.select.orderBy !== undefined && join.select.orderBy.length > 0) {\n const projected = new Set(\n join.select.columns\n .filter((column) => column.transform === undefined && column.castReal !== true)\n .map((column) => column.name),\n );\n const terms = join.select.orderBy;\n const columnTerms = terms.filter(\n (term): term is Extract<OrderTerm, { column: ColRef }> => \"column\" in term,\n );\n if (columnTerms.length === terms.length && columnTerms.every((term) => projected.has(term.column.name))) {\n const rendered = columnTerms.map((term) =>\n renderOrderTerm({\n dialect,\n term: {\n ...term,\n column: { table: \"__sub\", name: term.column.name, ...(term.column.castJsonb === undefined ? {} : { castJsonb: term.column.castJsonb }) },\n },\n collector,\n }),\n );\n aggOrder = ` ORDER BY ${rendered.join(\", \")}`;\n }\n }\n if (join.rowFormat !== \"positional\" && json.order !== \"inAggregate\") {\n // `to_json(\"__sub\".*)` names the columns itself; the runtime always sends\n // positional rows, so object rows stay a postgres construct.\n throw unsupportedCapability({ dialect: dialect.name, feature: \"object-format lateral rows\", hint: \"lateral relation rows render positional (rowFormat \\\"positional\\\") on this dialect\" });\n }\n const rowJson = join.rowFormat === \"positional\"\n ? renderPositionalRow({ dialect, join, subAlias })\n : `to_json(${subAlias}.*)`;\n const projection =\n join.agg === \"jsonArray\"\n ? `COALESCE(${json.arrayAgg}(${rowJson}${aggOrder}), ${json.emptyArray}) AS ${columnAlias}`\n : `${rowJson} AS ${columnAlias}`;\n const alias = dialect.quoteIdent({ name: join.alias });\n return `LEFT JOIN LATERAL (SELECT ${projection} FROM (${inner.text}) AS ${subAlias}) AS ${alias} ON true`;\n}\n\n/**\n * `(SELECT COUNT(*) FROM … WHERE …) AS \"alias\"` — one scalar per output row\n * ({@link CountSubquery}). Refuses anything but one ungrouped COUNT(*), so a\n * builder bug can never project a multi-row or multi-column subquery.\n */\nfunction renderCountSubquery(params: {\n dialect: SqlDialect;\n subquery: CountSubquery;\n collector: ParamCollector;\n}): string {\n const { dialect, subquery, collector } = params;\n const select = subquery.select;\n if (select.columns.length !== 0 || select.selectExpr?.kind !== \"countAll\" ||\n (select.aggregates?.length ?? 0) > 0 || select.rowNumber !== undefined ||\n select.groupBy !== undefined || select.having !== undefined ||\n select.limit !== undefined || select.offset !== undefined ||\n select.distinctOn !== undefined || select.distinct !== undefined || select.rowLock !== undefined ||\n select.countSubqueries !== undefined) {\n throw internalError({ message: \"count subquery must be one ungrouped COUNT(*)\" });\n }\n const inner = renderSelect({ dialect, statement: select, collector });\n return `(${inner.text}) AS ${dialect.quoteIdent({ name: subquery.alias })}`;\n}\n\n// ─── RETURNING ────────────────────────────────────────────────────\n\nfunction applyReturning(params: {\n dialect: SqlDialect;\n requested: readonly ReturningColumn[] | undefined;\n}): { suffix: string; status: \"native\" | \"omitted\" | \"none\" } {\n const { dialect, requested } = params;\n if (requested === undefined || requested.length === 0) {\n return { suffix: \"\", status: \"none\" };\n }\n if (!dialect.capabilities.returning) {\n return { suffix: \"\", status: \"omitted\" };\n }\n const columns = requested\n .map((column) => {\n if (typeof column === \"string\") return dialect.quoteIdent({ name: column });\n if (\"transform\" in column) {\n const name = dialect.quoteIdent({ name: column.name });\n return `${dialect.jsonTextProjection({ expression: name })} AS ${name}`;\n }\n const name = dialect.quoteIdent({ name: column.name });\n return `${textProjection({ dialect, expression: name })} AS ${name}`;\n })\n .join(\", \");\n return { suffix: ` RETURNING ${columns}`, status: \"native\" };\n}\n\n// ─── SELECT ───────────────────────────────────────────────────────\n\n/**\n * {@link KeyTableJoin}: `INNER JOIN (VALUES ROW(?, 0), …) AS alias (…) ON …`.\n * Mysql only — the one dialect whose default text equality is not byte\n * equality, and the shape was measured there (8.0.19+ `VALUES ROW`, already\n * this project's floor for the upsert row alias). Postgres needs a typed\n * parameter per member, so it renders only `citext` / `text` / `integer`\n * members (`CAST($n AS citext | text | bigint)`, plain `(…)` rows) — the\n * runtime emits it for a key tuple with a citext member; every other postgres\n * member refuses, and sqlite has no derived-table column list, so it refuses\n * rather than render an untested form.\n *\n * Ordinals are literal integers (row `i` → `i`): a statement-local index, not\n * data, so a key costs exactly the parameters its members bind — the same\n * budget as `col IN (?, …)`. Text members bind bare so the column's collation\n * decides; numeric members that travel as strings are CAST (see\n * {@link KeyTableMember}).\n *\n * The runtime emits a key table wherever `conflictKeyEquality.textIsBinaryByDefault`\n * is false (packages/runtime/src/relation-loader.ts, `associatesInDatabase`);\n * this refusal is by NAME, so a new dialect declaring that fact must also be\n * measured and admitted here.\n */\nfunction renderKeyTableJoin(params: { dialect: SqlDialect; join: KeyTableJoin; collector: ParamCollector }): string {\n const { dialect, join, collector } = params;\n // Postgres binds every member typed (an untyped VALUES cell would be\n // `text`, see {@link KeyTableMember}); `citext` and `text` are postgres\n // members, mysql binds text bare.\n const postgresMember = (member: KeyTableMember): boolean => member.kind === \"citext\" || member.kind === \"text\" || member.kind === \"integer\";\n const admitted = dialect.name === \"mysql\"\n ? join.members.every((member) => member.kind !== \"citext\" && member.kind !== \"text\")\n : dialect.name === \"postgres\" && join.members.every(postgresMember);\n if (!admitted) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"relation key table\",\n hint: \"the key-table join is mysql's relation association — this dialect compares relation keys by value\",\n });\n }\n if (join.columns.length === 0 || join.columns.length !== join.members.length) {\n throw internalError({ message: `key table needs one member per column, got ${join.members.length} for ${join.columns.length}` });\n }\n if (join.rows.length === 0) throw internalError({ message: \"key table needs at least one key row\" });\n for (const member of join.members) {\n if (member.kind === \"decimal\" && !(Number.isInteger(member.scale) && member.scale >= 0 && member.scale <= 30)) {\n throw internalError({ message: `key table decimal scale must be an integer 0-30, got ${String(member.scale)}` });\n }\n }\n const alias = dialect.quoteIdent({ name: join.alias });\n const memberNames = join.members.map((_, index) => dialect.quoteIdent({ name: `__vibe_k${index}` }));\n const rows = join.rows.map((row, ordinal) => {\n if (row.length !== join.members.length) {\n throw internalError({ message: `key table row has ${row.length} values for ${join.members.length} members` });\n }\n const cells = row.map((value, index) => {\n const placeholder = collector.add(value);\n const member = join.members[index] as KeyTableMember;\n switch (member.kind) {\n case \"integer\":\n return dialect.name === \"mysql\" ? `CAST(${placeholder} AS SIGNED)` : `CAST(${placeholder} AS bigint)`;\n case \"timestamp\":\n return `CAST(${placeholder} AS DATETIME(6))`;\n case \"time\":\n return `CAST(${placeholder} AS TIME(6))`;\n case \"decimal\":\n return `CAST(${placeholder} AS DECIMAL(65,${member.scale}))`;\n case \"citext\":\n return `CAST(${placeholder} AS citext)`;\n case \"text\":\n return `CAST(${placeholder} AS text)`;\n default:\n return placeholder;\n }\n });\n return dialect.name === \"mysql\" ? `ROW(${cells.join(\", \")}, ${ordinal})` : `(${cells.join(\", \")}, ${ordinal})`;\n });\n const on = join.columns.map((column, index) => `${quoteCol(dialect, column)} = ${alias}.${memberNames[index] as string}`).join(\" AND \");\n return `INNER JOIN (VALUES ${rows.join(\", \")}) AS ${alias} (${[...memberNames, dialect.quoteIdent({ name: join.ordinalAlias })].join(\", \")}) ON ${on}`;\n}\n\n// ─── Fix lane Q2 (D-03): derived-table LEFT JOIN ───\n\n/**\n * {@link LeftJoin}: `LEFT JOIN (<select>) AS \"alias\" ON \"alias\".\"k\" =\n * \"outer\".\"c\" [AND …]`. Portable. Refuses a builder bug: no ON pair, or a\n * derived projection with an unaliased column (the outer scope must see only\n * the reserved aliases, never a name that could make an unqualified outer\n * reference ambiguous). The derived select renders here, so its parameters\n * land in the shared sequence where they appear in the text.\n */\nfunction renderLeftJoin(params: { dialect: SqlDialect; join: LeftJoin; collector: ParamCollector }): string {\n const { dialect, join, collector } = params;\n if (join.on.length === 0) {\n throw internalError({ message: \"left join needs at least one ON pair\" });\n }\n if (join.select.columns.length === 0 || join.select.columns.some((column) => column.alias === undefined)) {\n throw internalError({ message: \"a left join's derived select must alias every projected column\" });\n }\n const inner = renderSelect({ dialect, statement: join.select, collector });\n const on = join.on\n .map((pair) => `${quoteCol(dialect, pair.left)} = ${quoteCol(dialect, pair.right)}`)\n .join(\" AND \");\n return `LEFT JOIN (${inner.text}) AS ${dialect.quoteIdent({ name: join.alias })} ON ${on}`;\n}\n\nfunction renderSelect(params: {\n dialect: SqlDialect;\n statement: SelectStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n if (statement.selectExpr !== undefined && statement.columns.length > 0 && statement.selectExpr.kind !== \"countAll\") {\n throw internalError({ message: \"only countAll can combine with a column list\" });\n }\n if (\n statement.selectExpr !== undefined &&\n statement.aggregates !== undefined &&\n statement.aggregates.length > 0\n ) {\n throw internalError({ message: \"selectExpr and aggregates cannot combine\" });\n }\n const columnList = statement.columns.map((column) => quoteProjection(dialect, column));\n if (statement.selectExpr !== undefined) {\n columnList.push(renderSelectExpr({ dialect, expr: statement.selectExpr }));\n }\n if (statement.aggregates !== undefined) {\n for (const selection of statement.aggregates) {\n const expression = renderAggRef(dialect, selection.agg);\n const projected = selection.castText === true ? textProjection({ dialect, expression }) : expression;\n columnList.push(`${projected} AS ${dialect.quoteIdent({ name: selection.alias })}`);\n }\n }\n if (statement.countSubqueries !== undefined) {\n for (const subquery of statement.countSubqueries) {\n columnList.push(renderCountSubquery({ dialect, subquery, collector }));\n }\n }\n if (statement.rowNumber !== undefined) {\n const rowNumber = statement.rowNumber;\n // An unpartitioned window numbers the whole select: only the position slot\n // of a lateral list level (`lateralJson.order: \"positionSlot\"`), which\n // always carries the level's order.\n if (rowNumber.partitionBy.length === 0 && rowNumber.orderBy.length === 0) {\n throw internalError({ message: \"rowNumber needs a partition column or an order\" });\n }\n const partition = rowNumber.partitionBy.length === 0 ? \"\" : `PARTITION BY ${rowNumber.partitionBy.map((column) => quoteCol(dialect, column)).join(\", \")}`;\n const order =\n rowNumber.orderBy.length === 0\n ? \"\"\n : `${partition === \"\" ? \"\" : \" \"}ORDER BY ${rowNumber.orderBy.map((term) => renderOrderTerm({ dialect, term, collector })).join(\", \")}`;\n columnList.push(\n `ROW_NUMBER() OVER (${partition}${order}) AS ${dialect.quoteIdent({ name: rowNumber.alias })}`,\n );\n }\n let distinctPrefix = statement.distinct === true ? \"DISTINCT \" : \"\";\n if (statement.distinct === true && statement.distinctOn !== undefined) {\n throw internalError({ message: \"distinct and distinctOn cannot combine\" });\n }\n if (statement.distinctOn !== undefined && statement.distinctOn.length > 0) {\n if (!dialect.capabilities.distinctOn) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"SELECT DISTINCT ON\",\n hint: \"postgres-only — the runtime emulates distinct client-side on this dialect\",\n });\n }\n distinctPrefix = `DISTINCT ON (${statement.distinctOn.map((column) => quoteCol(dialect, typedOrderRef({ statement, column }))).join(\", \")}) `;\n }\n const columns = columnList.length === 0 ? \"*\" : columnList.join(\", \");\n\n let from: string;\n // EPIC 4 (ST-07): key rows render where the table would, under its name.\n if (statement.fromKeys !== undefined) {\n from = renderKeyRows({ dialect, statement, keys: statement.fromKeys, collector });\n } else if (statement.fromUnion !== undefined) {\n // Fix lane Q2 (DB-07): a union page renders where a derived table would.\n from = `(${renderUnionPage({ dialect, statement, collector })}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else if (statement.keyPage !== undefined) {\n // Fix lane Q1 (DB-01): a per-key page renders where a derived table would.\n if (statement.fromSelect !== undefined || statement.table.alias !== undefined) {\n throw internalError({ message: \"keyPage uses table.name as the derived-table alias — fromSelect and table.alias must be unset\" });\n }\n from = `(${renderKeyPage({ dialect, page: statement.keyPage, collector })}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else if (statement.fromSelect !== undefined) {\n if (statement.table.alias !== undefined) {\n throw internalError({ message: \"fromSelect uses table.name as the subquery alias — table.alias must be unset\" });\n }\n // The subquery renders before WHERE/ORDER BY, so its parameters land in\n // the shared sequence exactly where they appear in the text.\n const inner = renderSelect({ dialect, statement: statement.fromSelect, collector });\n from = `(${inner.text}) AS ${dialect.quoteIdent({ name: statement.table.name })}`;\n } else {\n from = renderTable(dialect, statement.table);\n }\n let text = `SELECT ${distinctPrefix}${columns} FROM ${from}`;\n\n if (statement.innerJoins !== undefined && statement.innerJoins.length > 0) {\n for (const join of statement.innerJoins) {\n if (join.on.length === 0) {\n throw internalError({ message: \"inner join needs at least one ON pair\" });\n }\n const on = join.on\n .map((pair) => `${quoteCol(dialect, pair.left)} = ${quoteCol(dialect, pair.right)}`)\n .join(\" AND \");\n text += ` INNER JOIN ${renderTable(dialect, join.table)} ON ${on}`;\n }\n }\n if (statement.keyTable !== undefined) {\n text += ` ${renderKeyTableJoin({ dialect, join: statement.keyTable, collector })}`;\n }\n // Fix lane Q2 (D-03): derived-table LEFT JOINs (to-one relation orderBy).\n if (statement.leftJoins !== undefined && statement.leftJoins.length > 0) {\n if (statement.rowLock !== undefined) {\n throw internalError({ message: \"a locking read cannot carry a left join — postgres refuses FOR UPDATE on the nullable side of an outer join\" });\n }\n for (const join of statement.leftJoins) {\n text += ` ${renderLeftJoin({ dialect, join, collector })}`;\n }\n }\n\n if (statement.lateralJoins !== undefined && statement.lateralJoins.length > 0) {\n if (!dialect.capabilities.lateralJoin || dialect.lateralJson === null) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"LATERAL JOIN relation loading\",\n hint: 'use the portable \"query\" relation strategy on this dialect',\n });\n }\n for (const join of statement.lateralJoins) {\n text += ` ${renderLateralJoin({ dialect, join, collector })}`;\n }\n }\n\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n if (statement.groupBy !== undefined && statement.groupBy.length > 0) {\n text += ` GROUP BY ${statement.groupBy.map((column) => quoteCol(dialect, column)).join(\", \")}`;\n }\n if (statement.having !== undefined) {\n text += ` HAVING ${renderExpr({ dialect, expr: statement.having, collector })}`;\n }\n if (statement.orderBy !== undefined && statement.orderBy.length > 0) {\n const terms = statement.orderBy.map((term) =>\n renderOrderTerm({ dialect, term: \"column\" in term ? { ...term, column: typedOrderRef({ statement, column: term.column }) } : term, collector }),\n );\n text += ` ORDER BY ${terms.join(\", \")}`;\n }\n\n if (statement.limit !== undefined) {\n assertCount(statement.limit, \"limit\");\n text += ` LIMIT ${statement.limit}`;\n }\n if (statement.offset !== undefined) {\n assertCount(statement.offset, \"offset\");\n if (statement.limit === undefined && dialect.offsetRequiresLimit !== null) {\n text += ` LIMIT ${dialect.offsetRequiresLimit.limitText}`;\n }\n text += ` OFFSET ${statement.offset}`;\n }\n if (statement.rowLock !== undefined) {\n const clause = renderRowLockClause({ dialect, lock: statement.rowLock });\n if (clause !== null) text += ` ${clause}`;\n }\n\n return { text, values: collector.values, returning: \"none\" };\n}\n\n// ─── INSERT (incl. upsert) ────────────────────────────────────────\n\n/** The unnest source's relation alias and its ordinality column (`InsertStatement.unnest`). */\nconst UNNEST_ROWS_ALIAS = \"__vibe_rows\";\nconst UNNEST_ORDINALITY = \"ord\";\n\n/**\n * One cell of an unnest insert, as its array element: a plain value, SQL NULL,\n * or a Json cell's text (the column's storage must match). `DEFAULT`, the\n * database clock and any other object are refused — the builder keeps VALUES\n * for them, so reaching here is a builder defect.\n */\nfunction unnestElement(params: { value: unknown; column: string; jsonStorage: \"json\" | \"jsonb\" | undefined }): unknown {\n const { value, column, jsonStorage } = params;\n if (value === null || value === undefined) return null;\n if (isJsonParamCell(value)) {\n if (jsonStorage === undefined || (value.storage ?? \"jsonb\") !== jsonStorage) {\n throw internalError({ message: `unnest insert column \"${column}\" got a Json cell its declared type does not take` });\n }\n return value.text;\n }\n if (jsonStorage === undefined) {\n switch (typeof value) {\n case \"string\":\n case \"number\":\n case \"boolean\":\n case \"bigint\":\n return value;\n case \"object\":\n if (value instanceof Date || value instanceof Uint8Array) return value;\n }\n }\n throw internalError({ message: `unnest insert column \"${column}\" got a cell that is not a plain value (DEFAULT, the database clock, a document) — such rows keep VALUES` });\n}\n\n/**\n * `SELECT \"c1\", … FROM unnest($1::<type>[], …) WITH ORDINALITY AS\n * \"__vibe_rows\" (\"c1\", …, \"ord\") ORDER BY \"ord\"` — the source of an\n * {@link InsertStatement} carrying `unnest`. Collects ONE array per column, in\n * column order: the rows transposed, Json cells reduced to their text. The\n * aliases are positional, so no column name can collide with the ordinality\n * column; `ORDER BY \"ord\"` makes the insert consume rows in input order\n * (PostgreSQL promises no order without it).\n */\nfunction renderUnnestRows(params: {\n dialect: SqlDialect;\n statement: InsertStatement;\n members: readonly KeyListMember[];\n collector: ParamCollector;\n}): string {\n const { dialect, statement, members, collector } = params;\n if (dialect.bulkInsertForm !== \"unnest\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a bulk insert bound as typed arrays (INSERT … SELECT FROM unnest)\",\n hint: \"this dialect binds createMany rows as VALUES\",\n });\n }\n if (statement.columns.length === 0) throw internalError({ message: \"an unnest insert needs at least one column\" });\n if (members.length !== statement.columns.length) {\n throw internalError({ message: `unnest insert has ${members.length} column types for ${statement.columns.length} columns` });\n }\n if (statement.onConflict !== undefined && !(\"doNothing\" in statement.onConflict)) {\n throw internalError({ message: \"an unnest insert takes no DO UPDATE arm — upserts bind VALUES\" });\n }\n const aliases = statement.columns.map((_column, index) => dialect.quoteIdent({ name: `c${index + 1}` }));\n const arrays = members.map((member, index) => {\n const cast = postgresBulkInsertArrayCast({ dialect, member });\n const jsonStorage = member.type !== \"Json\" ? undefined : cast === \"text::json\" ? \"json\" : \"jsonb\";\n const column = statement.columns[index] as string;\n const values = statement.rows.map((row) => unnestElement({ value: row[index], column, jsonStorage }));\n return `${collector.add(values)}::${cast}[]`;\n });\n const ord = dialect.quoteIdent({ name: UNNEST_ORDINALITY });\n return `SELECT ${aliases.join(\", \")} FROM unnest(${arrays.join(\", \")}) WITH ORDINALITY AS ${dialect.quoteIdent({ name: UNNEST_ROWS_ALIAS })} (${aliases.join(\", \")}, ${ord}) ORDER BY ${ord}`;\n}\n\nfunction renderInsert(params: {\n dialect: SqlDialect;\n statement: InsertStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n if (statement.rows.length === 0) {\n throw internalError({ message: \"insert requires at least one row\" });\n }\n // No column named: every value is its column default (dialect.emptyInsert).\n const defaultValues = statement.columns.length === 0 && dialect.emptyInsert.form === \"defaultValues\";\n if (defaultValues && statement.rows.length !== 1) {\n throw internalError({ message: `${dialect.name} inserts an all-default row as DEFAULT VALUES, one row per statement` });\n }\n if (defaultValues && statement.onConflict !== undefined && !(dialect.emptyInsert.form === \"defaultValues\" && dialect.emptyInsert.conflictClause)) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a conflict clause on an all-default row (DEFAULT VALUES)\",\n hint: \"supply at least one column value, or drop the conflict clause\",\n });\n }\n for (const row of statement.rows) {\n if (row.length !== statement.columns.length) {\n throw internalError({\n message: `insert row has ${row.length} values but ${statement.columns.length} columns`,\n });\n }\n }\n\n const onConflict = statement.onConflict;\n const insertKeyword = \"INSERT INTO\";\n\n const columnList = statement.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n // EPIC C: rows bound as one typed array per column (`InsertStatement.unnest`).\n const unnestSource = statement.unnest === undefined ? undefined : renderUnnestRows({ dialect, statement, members: statement.unnest, collector });\n const rowsSql = unnestSource !== undefined ? \"\" : statement.rows\n .map(\n (row) =>\n `(${row\n .map((value) => {\n // Json cell: the param's type is pinned (`$n::text::jsonb` on\n // postgres) so OID-typed drivers cannot double-encode the document.\n if (isJsonParamCell(value)) return `${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n // Database-clock cell: the dialect's now() expression.\n if (isDbNowMarker(value)) {\n return dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector });\n }\n if (!isSqlDefaultCell(value)) return collector.add(value);\n // M4: a heterogeneous createMany cell defers to the COLUMN default.\n if (!dialect.rowDefaultKeyword) {\n throw internalError({\n message: `${dialect.name} cannot render a per-row DEFAULT cell — rows must be grouped by column set`,\n });\n }\n return \"DEFAULT\";\n })\n .join(\", \")})`,\n )\n .join(\", \");\n let text = defaultValues\n ? `${insertKeyword} ${renderTable(dialect, statement.table)} DEFAULT VALUES`\n : `${insertKeyword} ${renderTable(dialect, statement.table)} (${columnList}) ${unnestSource ?? `VALUES ${rowsSql}`}`;\n\n // Mysql can only name the incoming row through a ROW ALIAS declared right\n // after the VALUES list; postgres/sqlite have the built-in `excluded`\n // pseudo-relation and need nothing. Emitted only when the update arm\n // actually references the incoming row.\n if (\n onConflict !== undefined &&\n !(\"doNothing\" in onConflict) &&\n dialect.excludedRowRef.form === \"rowAlias\" &&\n Object.values(onConflict.update).some((value) => isExcludedRef(value) || (isSqlFragment(value) && sqlUsesIncoming({ fragment: value })))\n ) {\n text += ` AS ${dialect.quoteIdent({ name: dialect.excludedRowRef.alias })}`;\n }\n\n if (onConflict !== undefined) {\n if (\"doNothing\" in onConflict) {\n if (dialect.doNothingForm === \"onConflictDoNothing\") {\n let target = \"\";\n if (onConflict.constraint !== undefined) {\n if (dialect.name !== \"postgres\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target (ON CONFLICT ON CONSTRAINT)\",\n hint: \"only postgres names constraints in conflict targets — use a column-list target\",\n });\n }\n target = ` ON CONSTRAINT ${dialect.quoteIdent({ name: onConflict.constraint })}`;\n } else if (onConflict.columns !== undefined && onConflict.columns.length > 0) {\n target = ` (${onConflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")})`;\n if (onConflict.conflictWhere !== undefined) {\n // RAW predicate — the engines match it against the index's own\n // predicate structurally; parameters could never match (ast.ts).\n target += ` WHERE ${onConflict.conflictWhere}`;\n }\n }\n text += ` ON CONFLICT${target} DO NOTHING`;\n } else {\n // `duplicateKeyKeep` fires on ANY duplicate key. A bare column target\n // degrades to that documented wider skip; a REFINED target (named\n // constraint, partial-index predicate) must not silently widen —\n // the builder gates first, the renderer defends.\n if (onConflict.constraint !== undefined || onConflict.conflictWhere !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a refined conflict target (constraint / partial-index predicate) on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql skips on any duplicate key — drop the refinement or gate the call per dialect\",\n });\n }\n // A self-assignment: a duplicate changes nothing, every other error\n // (NOT NULL, range, foreign key) stays an error — never INSERT IGNORE.\n const keepName = onConflict.keepColumn ?? statement.columns[0];\n if (keepName === undefined) {\n throw internalError({ message: \"a skip-duplicates insert of an all-default row must name its keepColumn\" });\n }\n const keep = dialect.quoteIdent({ name: keepName });\n const current = `${dialect.quoteIdent({ name: statement.table.name })}.${keep}`;\n const flag = onConflict.duplicateFlag;\n if (flag !== undefined && !/^\\d{1,20}$/.test(flag)) {\n throw internalError({ message: `duplicateFlag must be a decimal literal, got ${JSON.stringify(flag)}` });\n }\n // The flag form reports a skipped duplicate through the insert id\n // (`LAST_INSERT_ID(S)` runs only on the duplicate arm).\n text += flag === undefined\n ? ` ON DUPLICATE KEY UPDATE ${keep} = ${current}`\n : ` ON DUPLICATE KEY UPDATE ${keep} = IF(LAST_INSERT_ID(${flag}), ${current}, ${current})`;\n }\n } else {\n const updates = Object.entries(onConflict.update);\n if (updates.length === 0) {\n throw internalError({ message: \"upsert update must set at least one column\" });\n }\n // The update arm's self-references MUST be table-qualified: inside\n // `ON CONFLICT … DO UPDATE SET`, postgres has BOTH the target row and\n // the `excluded` pseudo-relation in scope, so a bare `\"views\" + $n`\n // is rejected as ambiguous (SQLSTATE 42702). Sqlite and mysql accept\n // the qualified form with identical semantics (the pre-update row), so\n // one rule covers every dialect instead of a per-dialect divergence.\n const selfRef = dialect.quoteIdent({ name: statement.table.name });\n const assignments = renderAssignments({ dialect, entries: updates, collector, selfRef, allowExcluded: true, tableName: statement.table.name });\n if (dialect.upsertForm === \"onConflict\") {\n if (onConflict.lastInsertIdColumn !== undefined) {\n throw internalError({ message: \"lastInsertIdColumn is a mysql (onDuplicateKey) construct\" });\n }\n if (onConflict.constraint !== undefined && dialect.name !== \"postgres\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target (ON CONFLICT ON CONSTRAINT)\",\n hint: \"sqlite conflict targets are column lists — name the indexed columns instead\",\n });\n }\n if (onConflict.constraint !== undefined && onConflict.conflictWhere !== undefined) {\n throw internalError({\n message: \"a named-constraint conflict target already identifies the index — it cannot carry a partial predicate too\",\n });\n }\n // RAW predicate — matched structurally against the partial index's own\n // stored predicate, exactly like the DO NOTHING form (ast.ts).\n const partial = onConflict.conflictWhere === undefined ? \"\" : ` WHERE ${onConflict.conflictWhere}`;\n const target =\n onConflict.constraint !== undefined\n ? ` ON CONSTRAINT ${dialect.quoteIdent({ name: onConflict.constraint })}`\n : ` (${onConflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")})${partial}`;\n text += ` ON CONFLICT${target} DO UPDATE SET ${assignments}`;\n if (onConflict.updateWhere !== undefined) {\n if (!dialect.capabilities.conflictUpdateWhere) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a guarded conflict update (ON CONFLICT … DO UPDATE … WHERE)\",\n hint: \"run the guarded upsert as a find-then-write in a transaction instead\",\n });\n }\n text += ` WHERE ${renderExpr({ dialect, expr: onConflict.updateWhere, collector })}`;\n }\n } else {\n if (onConflict.updateWhere !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a guarded conflict update (ON DUPLICATE KEY UPDATE has no WHERE)\",\n hint: \"run the guarded upsert as a find-then-write in a transaction instead — the runtime does this when the dialect lacks conflictUpdateWhere\",\n });\n }\n if (onConflict.constraint !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a named-constraint conflict target on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql's ODKU fires on any duplicate key — no target can be named\",\n });\n }\n if (onConflict.conflictWhere !== undefined) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a partial-index conflict target on ON DUPLICATE KEY UPDATE\",\n hint: \"mysql's ODKU fires on any duplicate key — a partial arbiter cannot be selected; gate the call per dialect\",\n });\n }\n // B2: the update arm must record WHICH row it addressed — without this,\n // LAST_INSERT_ID() is stale after ODKU takes the update arm and the\n // read-back can resolve an unrelated row.\n const trick =\n onConflict.lastInsertIdColumn === undefined\n ? \"\"\n : `, ${dialect.quoteIdent({ name: onConflict.lastInsertIdColumn })} = LAST_INSERT_ID(${dialect.quoteIdent({ name: onConflict.lastInsertIdColumn })})`;\n text += ` ON DUPLICATE KEY UPDATE ${assignments}${trick}`;\n }\n }\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── UPDATE ───────────────────────────────────────────────────────\n\nfunction renderUpdate(params: {\n dialect: SqlDialect;\n statement: UpdateStatement;\n collector: ParamCollector;\n /** Chain steps defined before this one (a chain step only): a set value may read them. */\n earlier?: ReadonlySet<string>;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n const assignments = Object.entries(statement.set);\n if (assignments.length === 0) {\n throw internalError({ message: \"update must set at least one column\" });\n }\n const setSql = renderAssignments({ dialect, entries: assignments, collector, ...(params.earlier === undefined ? {} : { steps: params.earlier }) });\n let text = `UPDATE ${renderTable(dialect, statement.table)} SET ${setSql}`;\n\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── Assignments (SET / DO UPDATE SET) ────────────────────────────\n\n/**\n * `SET` assignments, shared by UPDATE and the upsert update arm.\n *\n * `selfRef` (the quoted target table) qualifies the READ side of an operation\n * that reads the column it writes — required inside `ON CONFLICT DO UPDATE`,\n * where a bare reference is ambiguous with `excluded` on postgres. The write\n * side is never qualified: `SET \"t\".\"col\" = …` is a syntax error everywhere.\n * A plain UPDATE passes no `selfRef` — it has no second relation in scope.\n */\n/**\n * The incoming row's column, qualified for this dialect: `excluded.\"col\"`\n * (postgres/sqlite) or `` `new`.`col` `` (mysql's row alias, declared after the\n * VALUES list by {@link renderInsert}).\n */\nfunction renderIncomingRowColumn(params: { dialect: SqlDialect; column: string }): string {\n const { dialect, column } = params;\n const ref = dialect.excludedRowRef;\n const qualifier = ref.form === \"keyword\" ? ref.name : dialect.quoteIdent({ name: ref.alias });\n return `${qualifier}.${dialect.quoteIdent({ name: column })}`;\n}\n\nfunction renderAssignments(params: {\n dialect: SqlDialect;\n entries: readonly (readonly [string, unknown])[];\n collector: ParamCollector;\n selfRef?: string;\n /** Only an upsert's update arm has an incoming row to reference. */\n allowExcluded?: boolean;\n tableName?: string;\n /** Lane C3: earlier chain steps a {@link StepColumnRef} value may read (a chain UPDATE step only). */\n steps?: ReadonlySet<string>;\n}): string {\n const { dialect, entries, collector, selfRef } = params;\n return entries\n .map(([name, value]) => {\n const column = dialect.quoteIdent({ name });\n const read = selfRef === undefined ? column : `${selfRef}.${column}`;\n // Lane C3: the value of an earlier step's one row — a scalar subquery,\n // whose own scope resolves the column (no clash with the target's).\n if (isStepColumnRef(value)) {\n if (params.steps === undefined || !params.steps.has(value.step)) {\n throw internalError({ message: `an UPDATE set value reads step \"${value.step}\", which is not an earlier chain step` });\n }\n return `${column} = (SELECT ${dialect.quoteIdent({ name: value.column })} FROM ${dialect.quoteIdent({ name: value.step })})`;\n }\n // The INCOMING row's value for this column — a column reference, so a\n // batched upsert writes each conflicting row's own value while binding\n // it exactly once (in the VALUES list).\n if (isSqlFragment(value)) {\n if (params.allowExcluded !== true || selfRef === undefined) throw internalError({ message: \"SQL assignment fragments require a conflict update\" });\n return `${column} = ${renderSqlFragment({ dialect, fragment: value, collector, conflict: { table: params.tableName! } })}`;\n }\n if (isExcludedRef(value)) {\n if (params.allowExcluded !== true) {\n throw internalError({\n message: `an incoming-row reference (${value.column}) is only meaningful inside an upsert's update arm`,\n });\n }\n return `${column} = ${renderIncomingRowColumn({ dialect, column: value.column })}`;\n }\n // V8: the column keeps its current value — a conflict update arm only.\n if (isSqlKeepCell(value)) {\n if (params.allowExcluded !== true || selfRef === undefined) throw internalError({ message: \"a keep-column cell is only meaningful inside an upsert's update arm\" });\n return `${column} = ${read}`;\n }\n // Json cell: same param-type pinning as the VALUES cells above.\n if (isJsonParamCell(value)) {\n return `${column} = ${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n }\n if (isSetOperation(value)) {\n const operand = collector.add(value.value);\n const numeric = dialect.name === \"sqlite\" && value.numericType === \"Decimal\" ? `CAST(${operand} AS REAL)` : operand;\n return `${column} = ${read} ${SET_OPERATION_SQL[value.__op]} ${numeric}`;\n }\n if (isDbNowMarker(value)) {\n return `${column} = ${dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector })}`;\n }\n if (isListSetOperation(value)) {\n assertScalarArrays(dialect, 'the scalar-list update operation \"push\"');\n if (value.__listOp === \"append\") {\n return `${column} = array_append(${read}, ${collector.add(value.value)})`;\n }\n return `${column} = ${read} || ${collector.add(value.value)}`;\n }\n return `${column} = ${collector.add(value)}`;\n })\n .join(\", \");\n}\n\n// ─── DELETE ───────────────────────────────────────────────────────\n\nfunction renderDelete(params: {\n dialect: SqlDialect;\n statement: DeleteStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n\n let text = `DELETE FROM ${renderTable(dialect, statement.table)}`;\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n\n const returning = applyReturning({ dialect, requested: statement.returning });\n return { text: text + returning.suffix, values: collector.values, returning: returning.status };\n}\n\n// ─── Statement chains (WITH … SELECT) ─────────────────────────────\n\n/** Derived-table aliases of a chain's verdict SELECT — no step may take them. */\nconst CHAIN_ROWS_ALIAS = \"__vibe_rows\";\nconst CHAIN_ONE_ALIAS = \"__vibe_one\";\n\n/**\n * `WITH \"a\" AS (…), \"b\" AS (…) <final SELECT>` — see {@link ChainStatement}.\n * Steps render in order through the ordinary statement renderers on ONE\n * shared collector, so parameters number in step order, then the verdict.\n *\n * The verdict form is `SELECT rows.cols, <verdict> FROM (SELECT 1) LEFT JOIN\n * (<union>) AS rows ON TRUE`: one row per written row, or ONE all-NULL row\n * carrying the verdict when the union is empty. A `LEFT JOIN`, not a NULL\n * marker branch inside the `UNION ALL`, so every column keeps its RETURNING\n * type — PostgreSQL resolves a nested UNION's untyped NULLs pairwise (two NULL\n * branches become `text`), which a bare marker branch would trip over.\n */\nfunction renderChain(params: {\n dialect: SqlDialect;\n statement: ChainStatement;\n collector: ParamCollector;\n}): RenderedQuery {\n const { dialect, statement, collector } = params;\n if (dialect.statementChain === null) {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"a statement chain (data-modifying WITH steps)\",\n hint: \"this dialect accepts only SELECT inside WITH — gate on SqlDialect.statementChain and keep the multi-statement path\",\n });\n }\n if (statement.steps.length === 0) throw internalError({ message: \"a statement chain needs at least one step\" });\n const defined = new Set<string>();\n const steps: string[] = [];\n for (const step of statement.steps) {\n if (step.name === CHAIN_ROWS_ALIAS || step.name === CHAIN_ONE_ALIAS || defined.has(step.name)) {\n throw internalError({ message: `chain step name \"${step.name}\" is reserved or repeated` });\n }\n const body = renderChainStep({ dialect, statement: step.statement, collector, earlier: defined });\n steps.push(`${dialect.quoteIdent({ name: step.name })} AS (${body})`);\n defined.add(step.name);\n }\n\n const result = statement.result;\n if (result.rowsFrom.length === 0 || result.columns.length === 0) {\n throw internalError({ message: \"a chain result needs at least one source step and one column\" });\n }\n for (const name of result.rowsFrom) {\n if (!defined.has(name)) throw internalError({ message: `chain result reads undefined step \"${name}\"` });\n }\n const columnList = result.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n const union = result.rowsFrom\n .map((name) => `SELECT ${columnList} FROM ${dialect.quoteIdent({ name })}`)\n .join(\" UNION ALL \");\n let select = union;\n if (result.verdict !== undefined || result.tally !== undefined || (result.veto !== undefined && result.veto.length > 0)) {\n const extra: string[] = [];\n for (const alias of [result.verdict?.alias, result.tally?.alias]) {\n if (alias !== undefined && result.columns.includes(alias)) {\n throw internalError({ message: `chain result alias \"${alias}\" collides with a result column` });\n }\n }\n const rows = dialect.quoteIdent({ name: CHAIN_ROWS_ALIAS });\n const projected = result.columns.map((name) => `${rows}.${dialect.quoteIdent({ name })}`);\n if (result.verdict !== undefined) {\n extra.push(`${renderExpr({ dialect, expr: result.verdict.expr, collector })} AS ${dialect.quoteIdent({ name: result.verdict.alias })}`);\n }\n if (result.tally !== undefined || (result.veto !== undefined && result.veto.length > 0)) {\n extra.push(renderTallyColumn({ dialect, result, defined, collector }));\n }\n select =\n `SELECT ${[...projected, ...extra].join(\", \")} FROM (SELECT 1) AS ${dialect.quoteIdent({ name: CHAIN_ONE_ALIAS })}` +\n ` LEFT JOIN (${union}) AS ${rows} ON TRUE`;\n }\n return { text: `WITH ${steps.join(\", \")} ${select}`, values: collector.values, returning: \"none\" };\n}\n\nfunction renderChainStep(params: {\n dialect: SqlDialect;\n statement: ChainStepStatement;\n collector: ParamCollector;\n earlier: ReadonlySet<string>;\n}): string {\n const { dialect, statement, collector } = params;\n switch (statement.kind) {\n case \"select\":\n return renderSelect({ dialect, statement, collector }).text;\n case \"insert\":\n return renderInsert({ dialect, statement, collector }).text;\n case \"insertSelect\":\n return renderInsertSelect({ dialect, statement, collector, earlier: params.earlier });\n case \"update\":\n return renderUpdate({ dialect, statement, collector, earlier: params.earlier }).text;\n case \"delete\":\n return renderDelete({ dialect, statement, collector }).text;\n }\n}\n\n/** One SELECT-list cell in a VALUES form: encoded value, Json cell or clock cell — never DEFAULT. */\nfunction renderSelectCell(params: { dialect: SqlDialect; value: unknown; collector: ParamCollector }): string {\n const { dialect, value, collector } = params;\n if (isJsonParamCell(value)) return `${collector.add(value.text)}${jsonCellCast(dialect, value)}`;\n if (isDbNowMarker(value)) return dialect.renderDbNow({ offsetSeconds: value.offsetSeconds, collector });\n if (isSqlDefaultCell(value)) {\n throw internalError({ message: \"DEFAULT is not allowed in an INSERT … SELECT list — omit the column instead\" });\n }\n return collector.add(value);\n}\n\n/**\n * `(SELECT cols FROM (VALUES (<typed NULL row>), ($1, $2), …) AS \"alias\"\n * (cols) OFFSET 1) AS \"alias\"` — see {@link ChainRowSource}: the first VALUES\n * row is one `(SELECT \"col\" FROM typedBy WHERE FALSE)` per column (a typed\n * NULL), which types every later parameter by the target table's own column;\n * `OFFSET 1` drops it again.\n */\nfunction renderRowSource(params: { dialect: SqlDialect; source: ChainRowSource; collector: ParamCollector }): string {\n const { dialect, source, collector } = params;\n if (source.columns.length === 0 || source.rows.length === 0) {\n throw internalError({ message: \"a row source needs at least one column and one row\" });\n }\n const typedBy = renderTable(dialect, source.typedBy);\n const columns = source.columns.map((name) => dialect.quoteIdent({ name }));\n const rows = [`(${columns.map((column) => `(SELECT ${column} FROM ${typedBy} WHERE FALSE)`).join(\", \")})`];\n for (const row of source.rows) {\n if (row.length !== source.columns.length) {\n throw internalError({ message: `row source row has ${row.length} values but ${source.columns.length} columns` });\n }\n rows.push(`(${row.map((value) => renderSelectCell({ dialect, value, collector })).join(\", \")})`);\n }\n const alias = dialect.quoteIdent({ name: source.alias });\n const columnList = columns.join(\", \");\n return `(SELECT ${columnList} FROM (VALUES ${rows.join(\", \")}) AS ${alias} (${columnList}) OFFSET 1) AS ${alias}`;\n}\n\n/**\n * The tally column guarded by the vetoes: `CASE WHEN NOT EXISTS (SELECT 1\n * FROM \"s\") THEN CAST('__vibe_veto:<token>:' || $n || ':' || (SELECT count(*)\n * FROM \"s\") AS integer) … ELSE (SELECT count(*) FROM \"a\") + … END`, `$n`\n * binding the veto's nonce. A veto with `minRows` above 1 (EPIC W) tests\n * `WHEN (SELECT count(*) FROM \"s\") < <minRows>` instead.\n *\n * The failing cast is how a plain SQL expression raises an error (SQLSTATE\n * 22P02, the marker quoted in the message). Its operand reads the step, so it\n * is NOT a constant: PostgreSQL folds constant CASE arms at plan time and\n * would raise even when the arm is never taken; this one is evaluated only\n * when its WHEN holds. The count it appends is the rows the step returned.\n */\nfunction renderTallyColumn(params: { dialect: SqlDialect; result: ChainResult; defined: ReadonlySet<string>; collector: ParamCollector }): string {\n const { dialect, result, defined, collector } = params;\n const tally = result.tally;\n if (tally === undefined) throw internalError({ message: \"a chain veto needs a tally column to guard\" });\n if (tally.steps.length === 0) throw internalError({ message: \"a chain tally needs at least one step\" });\n const step = (name: string): string => {\n if (!defined.has(name)) throw internalError({ message: `chain tally or veto reads undefined step \"${name}\"` });\n return dialect.quoteIdent({ name });\n };\n const count = (name: string): string => `(SELECT count(*) FROM ${step(name)})`;\n const sum = tally.steps.map(count).join(\" + \");\n const vetoes = result.veto ?? [];\n if (vetoes.length === 0) return `${sum} AS ${dialect.quoteIdent({ name: tally.alias })}`;\n const arms = vetoes.map((veto) => {\n if (!CHAIN_VETO_TOKEN_PATTERN.test(veto.token)) throw internalError({ message: `chain veto token \"${veto.token}\" is not a lower-case word` });\n if (typeof veto.nonce !== \"string\" || veto.nonce === \"\") throw internalError({ message: `chain veto \"${veto.token}\" needs a non-empty nonce` });\n const minRows = veto.minRows ?? 1;\n if (!Number.isSafeInteger(minRows) || minRows < 1) throw internalError({ message: `chain veto \"${veto.token}\" needs a positive integer minRows` });\n const when = minRows === 1 ? `WHEN NOT EXISTS (SELECT 1 FROM ${step(veto.step)})` : `WHEN ${count(veto.step)} < ${minRows}`;\n return `${when} THEN CAST('${CHAIN_VETO_PREFIX}${veto.token}:' || ${collector.add(veto.nonce)} || ':' || ${count(veto.step)} AS integer)`;\n });\n return `CASE ${arms.join(\" \")} ELSE ${sum} END AS ${dialect.quoteIdent({ name: tally.alias })}`;\n}\n\n/** `INSERT INTO t (cols) SELECT <cells> [FROM steps] [WHERE …] [RETURNING …]` — a chain step only. */\nfunction renderInsertSelect(params: {\n dialect: SqlDialect;\n statement: InsertSelectStatement;\n collector: ParamCollector;\n earlier: ReadonlySet<string>;\n}): string {\n const { dialect, statement, collector } = params;\n if (statement.columns.length === 0) throw internalError({ message: \"insert requires at least one column\" });\n if (statement.cells.length !== statement.columns.length) {\n throw internalError({\n message: `insert row has ${statement.cells.length} values but ${statement.columns.length} columns`,\n });\n }\n const from = statement.from ?? [];\n for (const name of from) {\n if (!params.earlier.has(name)) throw internalError({ message: `INSERT … SELECT reads step \"${name}\" before it is defined` });\n }\n const source = statement.source;\n if (source !== undefined && (params.earlier.has(source.alias) || from.includes(source.alias))) {\n throw internalError({ message: `row source alias \"${source.alias}\" collides with a chain step` });\n }\n const cells = statement.cells.map((value) => {\n if (isStepColumnRef(value)) {\n if (!from.includes(value.step) && value.step !== source?.alias) {\n throw internalError({ message: `cell reads step \"${value.step}\", which the INSERT … SELECT does not name in FROM` });\n }\n return `${dialect.quoteIdent({ name: value.step })}.${dialect.quoteIdent({ name: value.column })}`;\n }\n return renderSelectCell({ dialect, value, collector });\n });\n const columnList = statement.columns.map((name) => dialect.quoteIdent({ name })).join(\", \");\n let text = `INSERT INTO ${renderTable(dialect, statement.table)} (${columnList}) SELECT ${cells.join(\", \")}`;\n const relations = from.map((name) => dialect.quoteIdent({ name }));\n if (source !== undefined) relations.push(renderRowSource({ dialect, source, collector }));\n if (relations.length > 0) text += ` FROM ${relations.join(\" CROSS JOIN \")}`;\n if (statement.where !== undefined) {\n text += ` WHERE ${renderExpr({ dialect, expr: statement.where, collector })}`;\n }\n const conflict = statement.conflictDoNothing;\n if (conflict !== undefined) {\n if (conflict.columns.length === 0) throw internalError({ message: \"an INSERT … SELECT conflict clause needs at least one column\" });\n if (dialect.doNothingForm !== \"onConflictDoNothing\") {\n throw unsupportedCapability({\n dialect: dialect.name,\n feature: \"ON CONFLICT DO NOTHING on an INSERT … SELECT chain step\",\n hint: \"gate on SqlDialect.statementChain and keep the multi-statement path\",\n });\n }\n text += ` ON CONFLICT (${conflict.columns.map((name) => dialect.quoteIdent({ name })).join(\", \")}) DO NOTHING`;\n }\n return text + applyReturning({ dialect, requested: statement.returning }).suffix;\n}\n",
61
62
  "/**\n * LIKE pattern helpers.\n *\n * User input must be escaped before being embedded in a LIKE pattern, so that\n * `%`, `_` and `\\` in data match literally. All dialects use `\\` as the escape\n * character (sqlite only via the explicit ESCAPE clause the dialect appends —\n * see SqlDialect.likeEscapeClause).\n */\n\n/** Escape LIKE wildcards (`%`, `_`) and the escape character itself. */\nexport function escapeLikePattern(params: { raw: string }): string {\n return params.raw.replaceAll(\"\\\\\", \"\\\\\\\\\").replaceAll(\"%\", \"\\\\%\").replaceAll(\"_\", \"\\\\_\");\n}\n\n/** Pattern for a `contains` filter: `%value%` with the value escaped. */\nexport function containsPattern(params: { raw: string }): string {\n return `%${escapeLikePattern({ raw: params.raw })}%`;\n}\n\n/** Pattern for a `startsWith` filter: `value%` with the value escaped. */\nexport function startsWithPattern(params: { raw: string }): string {\n return `${escapeLikePattern({ raw: params.raw })}%`;\n}\n\n/** Pattern for an `endsWith` filter: `%value` with the value escaped. */\nexport function endsWithPattern(params: { raw: string }): string {\n return `%${escapeLikePattern({ raw: params.raw })}`;\n}\n\n/**\n * Escape sqlite GLOB metacharacters (`*`, `?`, `[`) via single-character\n * classes — GLOB has no ESCAPE clause, and LIKE's backslash escaping does NOT\n * apply to it (board #20; `]` is literal outside a class). Used by the\n * `strictMatch` renderer on dialects with `strictMatchStrategy: \"glob\"`.\n */\nexport function escapeGlobPattern(params: { raw: string }): string {\n return params.raw.replace(/[*?[]/g, (char) => `[${char}]`);\n}\n\n/**\n * The BOUND pattern a `strictMatch` pattern op renders, per strategy — the\n * ONE derivation point, used by the renderer AND the runtime's render-cache\n * mirror (which must bind the identical parameter, LEARNINGS mirror rule).\n */\nexport function strictMatchPattern(params: {\n strategy: \"native\" | \"glob\" | \"binary\";\n op: \"contains\" | \"startsWith\" | \"endsWith\";\n value: string;\n}): string {\n const { strategy, op, value } = params;\n if (strategy === \"glob\") {\n const inner = escapeGlobPattern({ raw: value });\n return op === \"contains\" ? `*${inner}*` : op === \"startsWith\" ? `${inner}*` : `*${inner}`;\n }\n return op === \"contains\"\n ? containsPattern({ raw: value })\n : op === \"startsWith\"\n ? startsWithPattern({ raw: value })\n : endsWithPattern({ raw: value });\n}\n\n// ─── Fix lane Q2 (D-06): collation prefilter of a strict prefix match ───\n\n/**\n * Does a `strictMatch` render the collation `LIKE` conjunct BEFORE its\n * byte-exact test? Only the `binary` strategy's (mysql) non-negated\n * `startsWith`: `(col LIKE ? AND col LIKE CAST(? AS BINARY))`, the same\n * pattern bound twice. A byte-exact prefix match is always a collation match\n * (a collation never separates identical characters, and the escaped prefix\n * plus `%` has no other wildcard), so the AND keeps exactly the binary test's\n * rows — while the plain conjunct lets a btree index on the column bound the\n * scan (measured on mysql 26.7: 5.92 → 0.24 ms, 100 002 → 3 rows read). The\n * ONE decision point for the renderer AND the runtime's render-cache mirror,\n * which must bind the pattern twice exactly when the renderer does.\n */\nexport function strictMatchCollationPrefilter(params: {\n strategy: \"native\" | \"glob\" | \"binary\";\n op: \"equals\" | \"contains\" | \"startsWith\" | \"endsWith\";\n negate: boolean;\n}): boolean {\n return params.strategy === \"binary\" && params.op === \"startsWith\" && !params.negate;\n}\n",
62
63
  "import { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\n\n/** Parsed custom type spelling; quoted identifiers retain their exact bytes. */\nexport type PostgresTypeName = {\n readonly namespace?: string;\n readonly name: string;\n readonly modifier: string;\n readonly array: boolean;\n};\n\nconst IDENTIFIER = '(?:\"(?:[^\"\\\\x00]|\"\")+\"|[a-zA-Z_][a-zA-Z_0-9$]*)';\nconst MODIFIER_VALUE = `(?:[+-]?\\\\d+|${IDENTIFIER}|'(?:[^'\\\\x00]|'')*')`;\nconst TYPE_NAME: RegExp = new RegExp(`^\\\\s*(${IDENTIFIER})(?:\\\\s*\\\\.\\\\s*(${IDENTIFIER}))?\\\\s*(\\\\(\\\\s*${MODIFIER_VALUE}(?:\\\\s*,\\\\s*${MODIFIER_VALUE})*\\\\s*\\\\))?\\\\s*((?:\\\\[\\\\s*\\\\]\\\\s*)*)$`);\nconst MODIFIER_TOKEN: RegExp = new RegExp(MODIFIER_VALUE, \"g\");\nfunction modifier(params: { raw?: string }): string {\n if (params.raw === undefined) return \"\";\n const tokens = params.raw.slice(1, -1).match(MODIFIER_TOKEN) ?? [];\n return `(${tokens.map((token) => /^[+-]?\\d+$/.test(token) ? BigInt(token).toString() : token.startsWith(\"'\") || token.startsWith('\"') ? token : token.toLowerCase()).join(\",\")})`;\n}\nfunction identifier(params: { value: string }): string {\n return params.value.startsWith('\"') ? params.value.slice(1, -1).replaceAll('\"\"', '\"') : params.value.toLowerCase();\n}\n\n/** Parse the identifier/modifier/array syntax used by PostgreSQL extension types. */\nexport function parsePostgresTypeName(params: { raw: string }): PostgresTypeName | undefined {\n const match = TYPE_NAME.exec(params.raw);\n if (match === null) return undefined;\n return {\n ...(match[2] === undefined ? {} : { namespace: identifier({ value: match[1]! }) }),\n name: identifier({ value: match[2] ?? match[1]! }),\n modifier: modifier({ ...(match[3] === undefined ? {} : { raw: match[3] }) }),\n array: (match[4]?.length ?? 0) > 0,\n };\n}\n\n/** Render a resolved type without depending on the executing connection's search path. */\nexport function renderPostgresTypeName(params: { dialect: SqlDialect; type: PostgresTypeName }): string {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"postgresTypeIdentity\" });\n const { dialect, type } = params;\n return `${type.namespace === undefined ? \"\" : `${dialect.quoteIdent({ name: type.namespace })}.`}${dialect.quoteIdent({ name: type.name })}${type.modifier}${type.array ? \"[]\" : \"\"}`;\n}\n\n/** Read catalog identity, or resolve an authored name in an explicitly chosen context. */\nexport function renderPostgresTypeIdentity(params: {\n dialect: SqlDialect;\n source: { readonly table: QualifiedSqlName; readonly column: string } | { readonly type: QualifiedSqlName | { readonly name: string } };\n}): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"postgresTypeIdentity\" });\n const collector = new ParamCollector(params.dialect);\n const { source } = params;\n let text: string;\n if (\"table\" in source) {\n text = `SELECT tn.nspname::text AS \"namespace\", base.typname::text AS \"name\" FROM pg_catalog.pg_attribute a JOIN pg_catalog.pg_class c ON c.oid = a.attrelid JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace JOIN pg_catalog.pg_type t ON t.oid = a.atttypid JOIN pg_catalog.pg_type base ON base.oid = CASE WHEN t.typelem <> 0 AND t.typlen = -1 THEN t.typelem ELSE t.oid END JOIN pg_catalog.pg_namespace tn ON tn.oid = base.typnamespace WHERE n.nspname = ${collector.add(source.table.namespace)} AND c.relname = ${collector.add(source.table.name)} AND a.attname = ${collector.add(source.column)} AND a.attnum > 0 AND NOT a.attisdropped`;\n } else {\n const name = renderPostgresTypeName({ dialect: params.dialect, type: { ...source.type, modifier: \"\", array: false } });\n text = `SELECT n.nspname::text AS \"namespace\", t.typname::text AS \"name\" FROM pg_catalog.pg_type t JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE t.oid = pg_catalog.to_regtype(${collector.add(name)})`;\n }\n return { text, values: collector.values, returning: \"none\" };\n}\n",
63
64
  "import { unsupportedCapability } from \"@vibeorm/schema\";\nimport type { QualifiedSqlName } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport { ParamCollector } from \"../params.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\n\n/** Read a stored default's function dependencies without evaluating its expression. */\nexport function renderPostgresDefaultFunctionIdentity(params: {\n dialect: SqlDialect;\n table: QualifiedSqlName;\n column: string;\n}): RenderedQuery {\n const { dialect, table, column } = params;\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"defaultFunctionIdentity\" });\n const collector = new ParamCollector(dialect);\n const namespace = collector.add(table.namespace);\n const name = collector.add(table.name);\n const field = collector.add(column);\n return {\n text: `SELECT pg_catalog.pg_get_expr(ad.adbin, ad.adrelid, false) AS \"expression\",\n pn.nspname::text AS \"functionNamespace\", p.proname::text AS \"functionName\",\n (p.pronargs = 0 AND p.provariadic = 0 AND p.prokind = 'f' AND NOT p.proretset) AS \"zeroArguments\",\n (p.prorettype = a.atttypid AND a.atttypmod = -1) AS \"exactResultType\"\nFROM pg_catalog.pg_attrdef ad\nJOIN pg_catalog.pg_attribute a ON a.attrelid = ad.adrelid AND a.attnum = ad.adnum\nJOIN pg_catalog.pg_class c ON c.oid = ad.adrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nJOIN pg_catalog.pg_depend d ON d.classid = 'pg_catalog.pg_attrdef'::pg_catalog.regclass AND d.objid = ad.oid AND d.refclassid = 'pg_catalog.pg_proc'::pg_catalog.regclass AND d.deptype = 'n'\nJOIN pg_catalog.pg_proc p ON p.oid = d.refobjid\nJOIN pg_catalog.pg_namespace pn ON pn.oid = p.pronamespace\nWHERE n.nspname = ${namespace} AND c.relname = ${name} AND a.attname = ${field}\n AND a.attnum > 0 AND NOT a.attisdropped AND a.attgenerated = ''`,\n values: collector.values,\n returning: \"none\",\n };\n}\n",
@@ -70,7 +71,7 @@
70
71
  "import { internalError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { SqlObjectIdentity } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\n\n/** Read a qualified object definition without changing the database. */\nexport function renderMigrationObjectQuery(params: { dialect: SqlDialect; identity: SqlObjectIdentity }): RenderedQuery {\n return objectQuery({ ...params, collector: new ParamCollector(params.dialect) });\n}\n\ntype InspectionCollector = Pick<ParamCollector, \"add\" | \"values\">;\n\nfunction objectQuery(params: { dialect: SqlDialect; identity: SqlObjectIdentity; collector: InspectionCollector }): RenderedQuery {\n const { dialect, identity: object, collector } = params;\n if (object.kind === \"namespace\") {\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"fixedNamespaces\" });\n return { text: `SELECT n.nspname::text AS \"name\" FROM pg_catalog.pg_namespace n WHERE n.nspname = ${collector.add(object.name)}`, values: collector.values, returning: \"none\" };\n }\n const physical = \"table\" in object ? object.table : object.name;\n const namespace = collector.add(physical.namespace);\n const name = collector.add(physical.name);\n let text: string;\n if (dialect.name === \"postgres\") {\n const relation = `FROM pg_catalog.pg_class c JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace`;\n const where = `n.nspname = ${namespace} AND c.relname = ${name}`;\n switch (object.kind) {\n case \"constraint\": {\n const enforcement = object.constraintType === \"foreignKey\" ? `, (SELECT bool_and(t.tgenabled IN ('O', 'A')) FROM pg_catalog.pg_trigger t WHERE t.tgconstraint = con.oid) AS \"triggersEnabled\"` : \"\";\n text = `SELECT con.contype::text AS \"type\", pg_catalog.pg_get_constraintdef(con.oid, false) AS \"definition\", con.convalidated AS \"validated\", con.condeferrable AS \"deferrable\", con.condeferred AS \"deferred\"${enforcement} ${relation} JOIN pg_catalog.pg_constraint con ON con.conrelid = c.oid WHERE ${where} AND con.conname = ${collector.add(object.name)}`;\n break;\n }\n case \"trigger\":\n text = `SELECT pg_catalog.pg_get_triggerdef(t.oid, false) AS \"definition\", t.tgenabled::text AS \"enabled\", pn.nspname::text AS \"functionNamespace\", p.proname::text AS \"functionName\", pg_catalog.pg_get_function_identity_arguments(p.oid) AS \"functionArguments\" ${relation} JOIN pg_catalog.pg_trigger t ON t.tgrelid = c.oid JOIN pg_catalog.pg_proc p ON p.oid = t.tgfoid JOIN pg_catalog.pg_namespace pn ON pn.oid = p.pronamespace WHERE ${where} AND t.tgname = ${collector.add(object.name)} AND NOT t.tgisinternal`;\n break;\n case \"function\":\n text = `SELECT pg_catalog.pg_get_functiondef(p.oid) AS \"definition\", p.provolatile::text AS \"volatility\", p.prosecdef AS \"securityDefiner\", CASE WHEN p.prosecdef THEN pg_catalog.pg_get_userbyid(p.proowner)::text ELSE NULL END AS \"definerOwner\", p.proisstrict AS \"strict\", p.proconfig::text AS \"config\", pg_catalog.pg_get_function_result(p.oid) AS \"result\" FROM pg_catalog.pg_proc p JOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace WHERE n.nspname = ${namespace} AND p.proname = ${name} AND p.prokind = 'f' AND ARRAY(SELECT tn.nspname || '.' || t.typname FROM unnest(p.proargtypes) WITH ORDINALITY a(oid, ord) JOIN pg_catalog.pg_type t ON t.oid = a.oid JOIN pg_catalog.pg_namespace tn ON tn.oid = t.typnamespace ORDER BY a.ord) = ${collector.add(object.argumentTypes.map((type) => `${type.namespace}.${type.name}`))}::text[]`;\n break;\n case \"view\":\n text = `SELECT pg_catalog.pg_get_viewdef(c.oid, false) AS \"definition\", c.relkind::text AS \"type\", c.reloptions::text AS \"options\" ${relation} WHERE ${where} AND c.relkind IN ('v', 'm')`;\n break;\n case \"sequence\":\n text = `SELECT pg_catalog.format_type(s.seqtypid, NULL) AS \"type\", s.seqstart::text AS \"start\", s.seqincrement::text AS \"increment\", s.seqmax::text AS \"max\", s.seqmin::text AS \"min\", s.seqcache::text AS \"cache\", s.seqcycle AS \"cycle\" ${relation} JOIN pg_catalog.pg_sequence s ON s.seqrelid = c.oid WHERE ${where}`;\n break;\n case \"column\": case \"columnDefault\": case \"generatedColumn\":\n text = `SELECT pg_catalog.format_type(a.atttypid, a.atttypmod) AS \"type\", a.attnotnull AS \"notNull\", a.attgenerated::text AS \"generated\", a.attidentity::text AS \"identity\", cn.nspname::text AS \"collationNamespace\", coll.collname::text AS \"collationName\", pg_catalog.pg_get_expr(d.adbin, d.adrelid, false) AS \"definition\" ${relation} JOIN pg_catalog.pg_attribute a ON a.attrelid = c.oid LEFT JOIN pg_catalog.pg_collation coll ON coll.oid = a.attcollation LEFT JOIN pg_catalog.pg_namespace cn ON cn.oid = coll.collnamespace LEFT JOIN pg_catalog.pg_attrdef d ON d.adrelid = c.oid AND d.adnum = a.attnum WHERE ${where} AND a.attname = ${collector.add(object.column)} AND a.attnum > 0 AND NOT a.attisdropped`;\n break;\n case \"index\":\n text = `SELECT pg_catalog.pg_get_indexdef(i.indexrelid, 0, false) AS \"definition\", i.indisunique AS \"unique\", i.indisvalid AS \"valid\", i.indisready AS \"ready\", con.conname::text AS \"constraint\", con.contype::text AS \"constraintType\" ${relation} JOIN pg_catalog.pg_index i ON i.indrelid = c.oid JOIN pg_catalog.pg_class ix ON ix.oid = i.indexrelid LEFT JOIN pg_catalog.pg_constraint con ON con.conindid = i.indexrelid AND con.contype IN ('p', 'u', 'x') WHERE ${where} AND ix.relname = ${collector.add(object.name)}`;\n break;\n case \"table\":\n text = `SELECT c.relkind::text AS \"type\", c.relrowsecurity AS \"rls\", c.relforcerowsecurity AS \"forceRls\", c.relpersistence::text AS \"persistence\", ARRAY(SELECT option FROM unnest(c.reloptions) AS option ORDER BY option COLLATE \"C\") AS \"options\" ${relation} WHERE ${where} AND c.relkind IN ('r', 'p')`;\n break;\n case \"enum\":\n text = `SELECT ARRAY(SELECT e.enumlabel::text FROM pg_catalog.pg_enum e WHERE e.enumtypid = t.oid ORDER BY e.enumsortorder) AS \"values\" FROM pg_catalog.pg_type t JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = ${namespace} AND t.typname = ${name} AND t.typtype = 'e'`;\n break;\n case \"postgresExtension\":\n text = `SELECT e.extversion::text AS \"version\", e.extrelocatable AS \"relocatable\" FROM pg_catalog.pg_extension e JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace WHERE n.nspname = ${namespace} AND e.extname = ${name}`;\n break;\n }\n } else if (dialect.name === \"mysql\") {\n if (object.kind === \"constraint\" && object.constraintType === \"exclusion\") throw unsupportedCapability({ dialect: \"mysql\", feature: \"exclusionConstraints\" });\n const mysql = mysqlFactsText({ dialect, identity: object, namespace, name, collector });\n if (mysql === undefined) throw unsupportedCapability({ dialect: \"mysql\", feature: `inspect:${object.kind}` });\n text = mysql;\n } else {\n if (physical.namespace !== \"main\" && physical.namespace !== \"temp\") throw unsupportedCapability({ dialect: \"sqlite\", feature: \"attachedSchemaInspection\" });\n // sqlite_schema retains source SQL. It is not a semantic SQL normalizer.\n const catalog = `${dialect.quoteIdent({ name: physical.namespace })}.sqlite_schema`;\n const kind = object.kind === \"table\" || object.kind === \"view\" ? object.kind : object.kind === \"trigger\" ? \"trigger\" : object.kind === \"index\" ? \"index\" : \"table\";\n if ([\"function\", \"sequence\", \"postgresExtension\", \"enum\"].includes(object.kind) || (object.kind === \"constraint\" && object.constraintType === \"exclusion\")) throw unsupportedCapability({ dialect: \"sqlite\", feature: `inspect:${object.kind}` });\n // Rebuild parameters: SQLite has positional placeholders, including unused values is invalid.\n const sqliteParams = new ParamCollector(dialect);\n if (object.kind === \"column\" || object.kind === \"columnDefault\" || object.kind === \"generatedColumn\") {\n text = `SELECT x.type AS type, x.\"notnull\" AS \"notNull\", x.pk AS primaryKeyPosition, x.hidden AS generated, x.dflt_value AS definition, (SELECT sql FROM ${catalog} WHERE name = ${sqliteParams.add(physical.name)} AND type = 'table') AS tableDefinition FROM pragma_table_xinfo(${sqliteParams.add(physical.name)}, ${sqliteParams.add(physical.namespace)}) x WHERE x.name = ${sqliteParams.add(object.column)}`;\n return { text, values: sqliteParams.values, returning: \"none\" };\n }\n const objectName = object.kind === \"trigger\" || object.kind === \"index\" ? object.name : physical.name;\n text = `SELECT sql AS definition, type AS type FROM ${catalog} WHERE name = ${sqliteParams.add(objectName)} AND type = ${sqliteParams.add(kind)}${object.kind === \"trigger\" ? ` AND tbl_name = ${sqliteParams.add(physical.name)}` : \"\"}`;\n return { text, values: sqliteParams.values, returning: \"none\" };\n }\n return { text, values: collector.values, returning: \"none\" };\n}\n\n/**\n * MySQL facts query text of one object (its namespace and name already bound),\n * or undefined for a kind MySQL cannot inspect. The one source of the MySQL\n * facts SQL: single reads and {@link renderMysqlObjectBatch} both render it.\n */\nfunction mysqlFactsText(params: { dialect: SqlDialect; identity: Exclude<SqlObjectIdentity, { kind: \"namespace\" }>; namespace: string; name: string; collector: InspectionCollector }): string | undefined {\n const { dialect, identity: object, namespace, name, collector } = params;\n switch (object.kind) {\n case \"view\": return `SELECT VIEW_DEFINITION AS definition, CHECK_OPTION AS checkOption, SECURITY_TYPE AS securityType, DEFINER AS definer FROM information_schema.VIEWS WHERE TABLE_SCHEMA = ${namespace} AND TABLE_NAME = ${name}`;\n case \"trigger\": return `SELECT ACTION_STATEMENT AS definition, ACTION_TIMING AS timing, EVENT_MANIPULATION AS event, ACTION_ORDER AS actionOrder, SQL_MODE AS sqlMode, DEFINER AS definer FROM information_schema.TRIGGERS WHERE TRIGGER_SCHEMA = ${namespace} AND EVENT_OBJECT_TABLE = ${name} AND TRIGGER_NAME = ${collector.add(object.name)}`;\n case \"function\": return `SELECT ROUTINE_DEFINITION AS definition, DTD_IDENTIFIER AS result, IS_DETERMINISTIC AS deterministic, SQL_DATA_ACCESS AS dataAccess, SECURITY_TYPE AS securityType, SQL_MODE AS sqlMode, DEFINER AS definer FROM information_schema.ROUTINES WHERE ROUTINE_SCHEMA = ${namespace} AND ROUTINE_NAME = ${name} AND ROUTINE_TYPE = 'FUNCTION'`;\n case \"column\": case \"columnDefault\": case \"generatedColumn\": return `SELECT COLUMN_TYPE AS type, IS_NULLABLE AS nullable, COLUMN_DEFAULT AS definition, GENERATION_EXPRESSION AS ${dialect.quoteIdent({ name: \"generated\" })}, EXTRA AS extra, COLLATION_NAME AS collation FROM information_schema.COLUMNS WHERE TABLE_SCHEMA = ${namespace} AND TABLE_NAME = ${name} AND COLUMN_NAME = ${collector.add(object.column)}`;\n case \"constraint\":\n if (object.constraintType === \"exclusion\") return undefined;\n return `SELECT tc.CONSTRAINT_TYPE AS type, tc.ENFORCED AS enforced, cc.CHECK_CLAUSE AS definition, rc.UPDATE_RULE AS onUpdate, rc.DELETE_RULE AS onDelete, rc.MATCH_OPTION AS matchOption FROM information_schema.TABLE_CONSTRAINTS tc LEFT JOIN information_schema.CHECK_CONSTRAINTS cc ON cc.CONSTRAINT_SCHEMA = tc.CONSTRAINT_SCHEMA AND cc.CONSTRAINT_NAME = tc.CONSTRAINT_NAME LEFT JOIN information_schema.REFERENTIAL_CONSTRAINTS rc ON rc.CONSTRAINT_SCHEMA = tc.CONSTRAINT_SCHEMA AND rc.TABLE_NAME = tc.TABLE_NAME AND rc.CONSTRAINT_NAME = tc.CONSTRAINT_NAME WHERE tc.TABLE_SCHEMA = ${namespace} AND tc.TABLE_NAME = ${name} AND tc.CONSTRAINT_NAME = ${collector.add(object.name)}`;\n case \"index\": return `SELECT INDEX_NAME AS name, NON_UNIQUE AS nonUnique, INDEX_TYPE AS method, IS_VISIBLE AS visible FROM information_schema.STATISTICS WHERE TABLE_SCHEMA = ${namespace} AND TABLE_NAME = ${name} AND INDEX_NAME = ${collector.add(object.name)} GROUP BY INDEX_NAME, NON_UNIQUE, INDEX_TYPE, IS_VISIBLE`;\n case \"table\": return `SELECT TABLE_TYPE AS type, ENGINE AS engine, TABLE_COLLATION AS collation FROM information_schema.TABLES WHERE TABLE_SCHEMA = ${namespace} AND TABLE_NAME = ${name}`;\n default: return undefined;\n }\n}\n\n/** The parts of one MySQL member query: its select list, its source with WHERE, and the column its rows are ordered by. */\ntype MysqlMemberParts = { readonly columns: string; readonly source: string; readonly ordinal: string };\n\nfunction mysqlMemberParts(params: { identity: SqlObjectIdentity; collector: InspectionCollector }): MysqlMemberParts | undefined {\n const { identity: object, collector } = params;\n if (object.kind !== \"function\" && object.kind !== \"index\" && object.kind !== \"constraint\") return undefined;\n const physical = \"table\" in object ? object.table : object.name;\n const namespace = collector.add(physical.namespace);\n const name = collector.add(physical.name);\n return object.kind === \"function\"\n ? { columns: \"PARAMETER_MODE AS mode, PARAMETER_NAME AS name, DTD_IDENTIFIER AS type, CHARACTER_SET_NAME AS characterSet, COLLATION_NAME AS collation\", source: `information_schema.PARAMETERS WHERE SPECIFIC_SCHEMA = ${namespace} AND SPECIFIC_NAME = ${name}`, ordinal: \"ORDINAL_POSITION\" }\n : object.kind === \"index\"\n ? { columns: \"COLUMN_NAME AS name, EXPRESSION AS expression, SUB_PART AS prefixLength, COLLATION AS collation\", source: `information_schema.STATISTICS WHERE TABLE_SCHEMA = ${namespace} AND TABLE_NAME = ${name} AND INDEX_NAME = ${collector.add(object.name)}`, ordinal: \"SEQ_IN_INDEX\" }\n : { columns: \"COLUMN_NAME AS name, REFERENCED_TABLE_SCHEMA AS referenceNamespace, REFERENCED_TABLE_NAME AS referenceTable, REFERENCED_COLUMN_NAME AS referenceColumn\", source: `information_schema.KEY_COLUMN_USAGE WHERE CONSTRAINT_SCHEMA = ${namespace} AND TABLE_NAME = ${name} AND CONSTRAINT_NAME = ${collector.add(object.name)}`, ordinal: \"ORDINAL_POSITION\" };\n}\n\n/** Ordered MySQL object members; no GROUP_CONCAT truncation can hide a definition change. */\nexport function renderMysqlObjectMembers(params: { dialect: SqlDialect; identity: SqlObjectIdentity }): RenderedQuery | undefined {\n if (params.dialect.name !== \"mysql\") return undefined;\n const collector = new ParamCollector(params.dialect);\n const parts = mysqlMemberParts({ identity: params.identity, collector });\n if (parts === undefined) return undefined;\n return { text: `SELECT ${parts.columns} FROM ${parts.source} ORDER BY ${parts.ordinal}`, values: collector.values, returning: \"none\" };\n}\n\n/**\n * One batched MySQL catalog read. Its rows carry `vibe_position` = i, the\n * branch that answers for request position `positions[i]`; member reads also\n * carry `vibe_ordinal`, the single query's ORDER BY column.\n */\nexport type MysqlObjectBatch = RenderedQuery & { readonly positions: readonly number[] };\n\n/**\n * Objects per batched MySQL statement. Larger unions cost the server more per\n * object (lane M probe, 17.10.2026: 100 per statement is as fast as single reads\n * or faster; 500 and 1 000 are slower), and 100 keeps a statement far below\n * the prepared-statement placeholder limit.\n */\nconst MYSQL_OBJECT_BATCH_SIZE = 100;\n\n/**\n * Ends every batched MySQL statement. `sql_select_limit` (session or global,\n * e.g. 1 000 under `mysql --safe-updates`) silently cuts the rows of a SELECT\n * without its own LIMIT, and a cut batch would read its last objects as\n * missing; an explicit LIMIT takes precedence over it. After the last\n * `UNION ALL` branch the LIMIT applies to the whole union. The value is MySQL's\n * largest row count, so nothing is ever cut.\n */\nconst MYSQL_BATCH_NO_ROW_LIMIT = \" LIMIT 18446744073709551615\";\n\n/** Branch-relative positions keep one statement text per shape and chunk size, so prepared statements are reused. */\nfunction mysqlBatches(params: { groups: ReadonlyMap<string, readonly { readonly position: number; readonly branch: (index: number) => string; readonly values: readonly unknown[] }[]>; suffix: string }): MysqlObjectBatch[] {\n const batches: MysqlObjectBatch[] = [];\n for (const group of params.groups.values()) {\n for (let offset = 0; offset < group.length; offset += MYSQL_OBJECT_BATCH_SIZE) {\n const chunk = group.slice(offset, offset + MYSQL_OBJECT_BATCH_SIZE);\n batches.push({\n text: `${chunk.map((entry, index) => entry.branch(index)).join(\" UNION ALL \")}${params.suffix}${MYSQL_BATCH_NO_ROW_LIMIT}`,\n values: chunk.flatMap((entry) => entry.values),\n returning: \"none\",\n positions: chunk.map((entry) => entry.position),\n });\n }\n }\n return batches;\n}\n\n/**\n * MySQL facts reads in bounded statements, grouped by query shape in request\n * order, 100 objects per statement. Each `UNION ALL` branch is the UNCHANGED\n * single-object query as a derived table, so the server matches names with the\n * single read's own `WHERE` and collation: the rows of a position are exactly the\n * rows {@link renderMigrationObjectQuery} returns for it. An identity MySQL cannot\n * inspect is in no batch; the caller reads it on its own (and gets its refusal).\n * The statement ends with `LIMIT 18446744073709551615`, so `sql_select_limit`\n * cannot cut it.\n */\nexport function renderMysqlObjectBatch(params: { dialect: SqlDialect; identities: readonly SqlObjectIdentity[] }): readonly MysqlObjectBatch[] {\n const { dialect } = params;\n if (dialect.name !== \"mysql\") throw unsupportedCapability({ dialect: dialect.name, feature: \"batchedMigrationInspection\" });\n const position = dialect.quoteIdent({ name: \"vibe_position\" });\n const groups = new Map<string, { position: number; branch: (index: number) => string; values: readonly unknown[] }[]>();\n for (const [index, identity] of params.identities.entries()) {\n if (identity.kind === \"namespace\") continue;\n const physical = \"table\" in identity ? identity.table : identity.name;\n const collector = new ParamCollector(dialect);\n const text = mysqlFactsText({ dialect, identity, namespace: collector.add(physical.namespace), name: collector.add(physical.name), collector });\n if (text === undefined) continue;\n const group = groups.get(text) ?? [];\n group.push({ position: index, branch: (branch) => `SELECT ${branch} AS ${position}, q.* FROM (${text}) q`, values: collector.values });\n groups.set(text, group);\n }\n return mysqlBatches({ groups, suffix: \"\" });\n}\n\n/**\n * MySQL member reads (function parameters, index and constraint columns) in\n * bounded statements, grouped by kind in request order, 100 objects per\n * statement. Each branch is the single member query's select list and `WHERE`\n * plus its ORDER BY column as `vibe_ordinal`; MySQL ignores an ORDER BY inside a\n * union branch, so the statement orders by `vibe_position, vibe_ordinal` (then\n * `LIMIT 18446744073709551615`, so `sql_select_limit` cannot cut it). Rows\n * of a position equal {@link renderMysqlObjectMembers}' rows in its order\n * whenever that object's ordinals are distinct; the caller checks that.\n */\nexport function renderMysqlObjectMembersBatch(params: { dialect: SqlDialect; identities: readonly SqlObjectIdentity[] }): readonly MysqlObjectBatch[] {\n const { dialect } = params;\n if (dialect.name !== \"mysql\") throw unsupportedCapability({ dialect: dialect.name, feature: \"batchedMigrationInspection\" });\n const position = dialect.quoteIdent({ name: \"vibe_position\" });\n const ordinal = dialect.quoteIdent({ name: \"vibe_ordinal\" });\n const groups = new Map<string, { position: number; branch: (index: number) => string; values: readonly unknown[] }[]>();\n for (const [index, identity] of params.identities.entries()) {\n const collector = new ParamCollector(dialect);\n const parts = mysqlMemberParts({ identity, collector });\n if (parts === undefined) continue;\n const group = groups.get(identity.kind) ?? [];\n group.push({ position: index, branch: (branch) => `SELECT ${branch} AS ${position}, ${parts.ordinal} AS ${ordinal}, ${parts.columns} FROM ${parts.source}`, values: collector.values });\n groups.set(identity.kind, group);\n }\n return mysqlBatches({ groups, suffix: ` ORDER BY ${position}, ${ordinal}` });\n}\n\n/** PostgreSQL dependency addresses are returned as server-owned strings, never guessed from SQL. */\nexport function renderMigrationDependencies(params: { dialect: SqlDialect; identity: SqlObjectIdentity }): RenderedQuery {\n return dependencyQuery({ ...params, collector: new ParamCollector(params.dialect) });\n}\n\nfunction dependencyQuery(params: { dialect: SqlDialect; identity: SqlObjectIdentity; collector: InspectionCollector }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"catalogDependencies\" });\n const object = params.identity;\n const collector = params.collector;\n if (object.kind === \"namespace\") {\n const namespace = collector.add(object.name);\n return { text: `SELECT DISTINCT json_build_array(d.deptype, a.type, a.object_names, a.object_args)::text AS address FROM pg_catalog.pg_namespace n JOIN pg_catalog.pg_depend d ON d.classid = 'pg_namespace'::regclass AND d.objid = n.oid AND d.objsubid = 0 CROSS JOIN LATERAL pg_catalog.pg_identify_object_as_address(d.refclassid, d.refobjid, d.refobjsubid) a WHERE n.nspname = ${namespace} ORDER BY address`, values: collector.values, returning: \"none\" };\n }\n const physical = \"table\" in object ? object.table : object.name;\n const namespace = collector.add(physical.namespace);\n const name = collector.add(physical.name);\n const relation = `SELECT c.oid FROM pg_catalog.pg_class c JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE n.nspname = ${namespace} AND c.relname = ${name}`;\n let source: string;\n switch (object.kind) {\n case \"constraint\": source = `SELECT 'pg_constraint'::regclass AS classid, con.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_constraint con WHERE con.conrelid = (${relation}) AND con.conname = ${collector.add(object.name)}`; break;\n case \"trigger\": source = `SELECT 'pg_trigger'::regclass AS classid, t.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_trigger t WHERE t.tgrelid = (${relation}) AND t.tgname = ${collector.add(object.name)}`; break;\n case \"columnDefault\": case \"generatedColumn\": source = `SELECT 'pg_attrdef'::regclass AS classid, d.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_attrdef d JOIN pg_catalog.pg_attribute a ON a.attrelid = d.adrelid AND a.attnum = d.adnum WHERE a.attrelid = (${relation}) AND a.attname = ${collector.add(object.column)}`; break;\n case \"column\": source = `SELECT 'pg_class'::regclass AS classid, a.attrelid AS objid, a.attnum AS objsubid FROM pg_catalog.pg_attribute a WHERE a.attrelid = (${relation}) AND a.attname = ${collector.add(object.column)}`; break;\n case \"view\": source = `SELECT 'pg_rewrite'::regclass AS classid, r.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_rewrite r WHERE r.ev_class = (${relation})`; break;\n case \"index\": source = `SELECT 'pg_class'::regclass AS classid, i.indexrelid AS objid, 0 AS objsubid FROM pg_catalog.pg_index i JOIN pg_catalog.pg_class c ON c.oid = i.indexrelid WHERE i.indrelid = (${relation}) AND c.relname = ${collector.add(object.name)}`; break;\n case \"function\": source = `SELECT 'pg_proc'::regclass AS classid, p.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_proc p JOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace WHERE n.nspname = ${namespace} AND p.proname = ${name} AND ARRAY(SELECT tn.nspname || '.' || t.typname FROM unnest(p.proargtypes) WITH ORDINALITY a(oid, ord) JOIN pg_catalog.pg_type t ON t.oid = a.oid JOIN pg_catalog.pg_namespace tn ON tn.oid = t.typnamespace ORDER BY a.ord) = ${collector.add(object.argumentTypes.map((type) => `${type.namespace}.${type.name}`))}::text[]`; break;\n case \"enum\": source = `SELECT 'pg_type'::regclass AS classid, t.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_type t JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = ${namespace} AND t.typname = ${name} AND t.typtype = 'e'`; break;\n case \"postgresExtension\": source = `SELECT 'pg_extension'::regclass AS classid, e.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_extension e JOIN pg_catalog.pg_namespace n ON n.oid = e.extnamespace WHERE n.nspname = ${namespace} AND e.extname = ${name}`; break;\n default: source = `SELECT 'pg_class'::regclass AS classid, c.oid AS objid, 0 AS objsubid FROM pg_catalog.pg_class c WHERE c.oid = (${relation})`; break;\n }\n return { text: `SELECT DISTINCT json_build_array(d.deptype, a.type, a.object_names, a.object_args)::text AS address FROM (${source}) s JOIN pg_catalog.pg_depend d ON d.classid = s.classid AND d.objid = s.objid AND d.objsubid = s.objsubid CROSS JOIN LATERAL pg_catalog.pg_identify_object_as_address(d.refclassid, d.refobjid, d.refobjsubid) a ORDER BY address`, values: collector.values, returning: \"none\" };\n}\n\nfunction inspectionReferences(params: { dialect: SqlDialect }): InspectionCollector {\n const values: unknown[] = [];\n return { values, add(value) {\n values.push(value);\n return `request.${params.dialect.quoteIdent({ name: `p${values.length}` })}`;\n } };\n}\n\n/** One batched PostgreSQL catalog read and the request positions it answers for. */\nexport type MigrationObjectBatch = RenderedQuery & { readonly positions: readonly number[] };\n\n/** Batch PostgreSQL facts and dependencies by SQL shape, retaining each requested position. */\nexport function renderMigrationObjectBatch(params: { dialect: SqlDialect; identities: readonly SqlObjectIdentity[] }): readonly MigrationObjectBatch[] {\n const { dialect } = params;\n if (dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: dialect.name, feature: \"batchedMigrationInspection\" });\n const groups = new Map<string, { identity: SqlObjectIdentity; position: number }[]>();\n for (const [position, identity] of params.identities.entries()) {\n // One group per distinct facts/dependency SQL pair; columnDefault and generatedColumn render the same pair.\n const kind = identity.kind === \"constraint\" ? `${identity.kind}:${identity.constraintType}` : identity.kind === \"generatedColumn\" ? \"columnDefault\" : identity.kind;\n const group = groups.get(kind) ?? [];\n group.push({ identity, position });\n groups.set(kind, group);\n }\n return [...groups.values()].map((group): MigrationObjectBatch => {\n const identity = group[0]!.identity;\n const facts = objectQuery({ dialect, identity, collector: inspectionReferences({ dialect }) });\n const dependencies = dependencyQuery({ dialect, identity, collector: inspectionReferences({ dialect }) });\n // Both queries read request.p1..pN, so they must bind the identity's values in one order.\n if (JSON.stringify(dependencies.values) !== JSON.stringify(facts.values)) throw internalError({ message: \"Batched catalog queries bind their identity in different orders\", meta: { kind: identity.kind } });\n const columns = facts.values.map((value, index) => `${dialect.quoteIdent({ name: `p${index + 1}` })} ${Array.isArray(value) ? \"text[]\" : \"text\"}`);\n const requests = group.map(({ identity, position }) => ({ position, ...Object.fromEntries(renderMigrationObjectQuery({ dialect, identity }).values.map((value, index) => [`p${index + 1}`, value])) }));\n // Bind serialized JSON as text; a jsonb wire parameter is JSON-encoded again by Bun.\n const collector = new ParamCollector(dialect);\n return {\n text: `SELECT request.position, to_jsonb(facts) AS facts, ARRAY(SELECT address FROM (${dependencies.text}) dependency ORDER BY address) AS \"dependencyAddresses\" FROM jsonb_to_recordset(${collector.add(JSON.stringify(requests))}::text::jsonb) AS request(position integer, ${columns.join(\", \")}) CROSS JOIN LATERAL (${facts.text}) facts`,\n values: collector.values,\n returning: \"none\",\n positions: group.map(({ position }) => position),\n };\n });\n}\n\n/** Record the database normalization context in generated metadata. */\nexport function renderMigrationServerVersion(params: { dialect: SqlDialect }): RenderedQuery {\n return { text: params.dialect.name === \"sqlite\" ? \"SELECT sqlite_version() AS version\" : \"SELECT version() AS version\", values: [], returning: \"none\" };\n}\n\n/** Inspectable current namespace; core PostgreSQL schema mapping remains public. */\nexport function renderMigrationNamespace(params: { dialect: SqlDialect }): RenderedQuery {\n return { text: params.dialect.name === \"mysql\" ? \"SELECT DATABASE() AS namespace\" : params.dialect.name === \"sqlite\" ? \"SELECT 'main' AS namespace\" : \"SELECT 'public' AS namespace\", values: [], returning: \"none\" };\n}\n\n/** PostgreSQL CHECK probe uses the actual table's type context and is always rolled back. */\nexport function renderCheckProbe(params: { dialect: SqlDialect; table: { namespace: string; name: string }; expression: string; name: string }): RenderedQuery {\n if (params.dialect.name !== \"postgres\") throw unsupportedCapability({ dialect: params.dialect.name, feature: \"rollbackCheckProbe\" });\n const q = (name: string): string => params.dialect.quoteIdent({ name });\n return { text: `ALTER TABLE ${q(params.table.namespace)}.${q(params.table.name)} ADD CONSTRAINT ${q(params.name)} CHECK (${params.expression}) NOT VALID`, values: [], returning: \"none\" };\n}\n",
71
72
  "/**\n * PostgreSQL migration-operations SQL: migration-owned session settings and\n * the read-only catalog probes a nontransactional migration needs to establish\n * what actually happened before it resumes.\n *\n * Why these live here and not in @vibeorm/migrate: every SQL-text decision\n * belongs to a dialect module (constitution rule 4). The migrate runner\n * decides WHEN to ask; this file decides WHAT is asked.\n *\n * Honesty notes carried by these shapes:\n *\n * - `lock_timeout` bounds how long ONE statement waits for a lock. It does not\n * make an operation online, and it does not bound the lock's HOLD time once\n * acquired. The runner surfaces that as risk output, not as a guarantee.\n * - The index probe reports `indisvalid`/`indisready` AND the full deparsed\n * definition, because `CREATE INDEX CONCURRENTLY` can fail leaving an\n * invalid index behind that `IF NOT EXISTS` would happily accept.\n * - Every probe is scoped to `current_schema()`, the same schema the migrate\n * DDL renderers write into.\n */\n\nimport { VibeError, unsupportedCapability } from \"@vibeorm/schema\";\nimport type { SqlDialect } from \"../dialect.ts\";\nimport type { RenderedQuery } from \"../render.ts\";\nimport { ParamCollector } from \"../params.ts\";\n\n// ─── Session settings ─────────────────────────────────────────────\n\n/** Session settings a migration may scope to its own work. */\nexport type MigrationSessionSetting = \"lock_timeout\" | \"statement_timeout\";\n\n/**\n * A PostgreSQL interval-ish setting value as `current_setting` returns it\n * (`0`, `5s`, `250ms`, `2min`). Anything else is refused rather than\n * interpolated — these values are written into SQL text, not parameters,\n * because `SET` takes no placeholders.\n */\nconst SETTING_VALUE = /^[0-9]+(?:\\.[0-9]+)?\\s*(?:us|ms|s|min|h|d)?$/;\n\nfunction requirePostgres(params: { dialect: SqlDialect; feature: string }): void {\n if (params.dialect.name !== \"postgres\") {\n throw unsupportedCapability({ dialect: params.dialect.name, feature: params.feature });\n }\n}\n\n/** Read the session's current `lock_timeout` / `statement_timeout`, to restore them later. */\nexport function renderMigrationSessionRead(params: { dialect: SqlDialect }): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"migrationSessionSettings\" });\n return {\n text: `SELECT pg_catalog.current_setting('lock_timeout') AS \"lockTimeout\", pg_catalog.current_setting('statement_timeout') AS \"statementTimeout\"`,\n values: [],\n returning: \"none\",\n };\n}\n\n/**\n * Scope a setting to the migration's own work. Milliseconds only, and only a\n * non-negative safe integer: 0 means \"no limit\", which is PostgreSQL's own\n * default and the value a restore falls back to.\n */\nexport function renderMigrationSessionSet(params: {\n dialect: SqlDialect;\n setting: MigrationSessionSetting;\n milliseconds: number;\n /** `SET LOCAL` — reverted by the enclosing COMMIT/ROLLBACK, so no restore is needed. */\n local?: boolean;\n}): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"migrationSessionSettings\" });\n const { milliseconds, setting } = params;\n if (!Number.isSafeInteger(milliseconds) || milliseconds < 0) {\n throw new VibeError({\n code: \"VIBE_MIGRATION\",\n message: `${setting} must be a non-negative integer number of milliseconds (got ${String(milliseconds)})`,\n meta: { reason: \"execution-metadata-invalid\", setting, value: milliseconds },\n });\n }\n return { text: `SET ${params.local === true ? \"LOCAL \" : \"\"}${setting} = '${milliseconds}ms'`, values: [], returning: \"none\" };\n}\n\n/**\n * Put a setting back to the value {@link renderMigrationSessionRead} reported.\n * An unrecognized value restores the server default with `RESET` instead of\n * being interpolated — never guess at SQL text read back from a session.\n */\nexport function renderMigrationSessionRestore(params: {\n dialect: SqlDialect;\n setting: MigrationSessionSetting;\n value: string;\n}): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"migrationSessionSettings\" });\n const trimmed = params.value.trim();\n const text = SETTING_VALUE.test(trimmed)\n ? `SET ${params.setting} = '${trimmed}'`\n : `RESET ${params.setting}`;\n return { text, values: [], returning: \"none\" };\n}\n\n// ─── Catalog probes ───────────────────────────────────────────────\n\n/**\n * Everything needed to decide whether a `CREATE INDEX CONCURRENTLY` finished:\n * the index's validity, its access method, its uniqueness, its key-column\n * expressions as PostgreSQL itself deparses them (newline-joined so every\n * adapter decodes one plain text column), its partial predicate and the full\n * `pg_get_indexdef` text for the operator to read in an error message.\n * Complete recovery also reads NULL uniqueness and lossless ordered JSON text\n * for key and included definitions. PostgreSQL 16/17/18 expose these fields.\n *\n * `indisvalid = false` is the state a cancelled/failed concurrent build\n * leaves behind: the index exists, is skipped by the planner, and is still\n * maintained by writes. `IF NOT EXISTS` cannot tell that apart from success.\n */\nexport function renderIndexStateQuery(params: { dialect: SqlDialect; index: string }): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"concurrentIndexRecovery\" });\n const collector = new ParamCollector(params.dialect);\n const name = collector.add(params.index);\n return {\n text: `SELECT c.relname::text AS \"index\",\n t.relname::text AS \"table\",\n am.amname::text AS \"method\",\n i.indisunique AS \"unique\",\n i.indnullsnotdistinct AS \"nullsNotDistinct\",\n pg_catalog.array_to_json(ARRAY(SELECT pg_catalog.pg_get_indexdef(i.indexrelid, k.k, true)\n FROM pg_catalog.generate_series(1, i.indnkeyatts) AS k(k) ORDER BY k.k))::text AS \"keyColumns\",\n pg_catalog.array_to_json(ARRAY(SELECT pg_catalog.pg_get_indexdef(i.indexrelid, k.k, true)\n FROM pg_catalog.generate_series(i.indnkeyatts + 1, i.indnatts) AS k(k) ORDER BY k.k))::text AS \"includedColumns\",\n i.indisvalid AS \"valid\",\n i.indisready AS \"ready\",\n pg_catalog.pg_get_expr(i.indpred, i.indrelid) AS \"predicate\",\n pg_catalog.pg_get_indexdef(i.indexrelid) AS \"definition\",\n (SELECT string_agg(pg_catalog.pg_get_indexdef(i.indexrelid, k.k, true), E'\\\\n' ORDER BY k.k)\n FROM pg_catalog.generate_series(1, i.indnkeyatts) AS k(k)) AS \"columns\"\nFROM pg_catalog.pg_class c\nJOIN pg_catalog.pg_index i ON i.indexrelid = c.oid\nJOIN pg_catalog.pg_class t ON t.oid = i.indrelid\nJOIN pg_catalog.pg_am am ON am.oid = c.relam\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname = pg_catalog.current_schema() AND c.relname = ${name}`,\n values: collector.values,\n returning: \"none\",\n };\n}\n\n/** Whether a named constraint exists on a table, and whether it is validated. */\nexport function renderConstraintStateQuery(params: {\n dialect: SqlDialect;\n table: string;\n constraint: string;\n}): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"stagedConstraints\" });\n const collector = new ParamCollector(params.dialect);\n const table = collector.add(params.table);\n const constraint = collector.add(params.constraint);\n return {\n text: `SELECT con.conname::text AS \"constraint\",\n rel.relname::text AS \"table\",\n con.contype::text AS \"type\",\n con.convalidated AS \"validated\",\n pg_catalog.pg_get_constraintdef(con.oid) AS \"definition\"\nFROM pg_catalog.pg_constraint con\nJOIN pg_catalog.pg_class rel ON rel.oid = con.conrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = rel.relnamespace\nWHERE n.nspname = pg_catalog.current_schema() AND rel.relname = ${table} AND con.conname = ${constraint}`,\n values: collector.values,\n returning: \"none\",\n };\n}\n\n/** Whether a relation of that physical name exists in the migration's schema. */\nexport function renderRelationStateQuery(params: { dialect: SqlDialect; table: string }): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"renameRecovery\" });\n const collector = new ParamCollector(params.dialect);\n const table = collector.add(params.table);\n return {\n text: `SELECT c.relname::text AS \"table\", c.relkind::text AS \"kind\"\nFROM pg_catalog.pg_class c\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname = pg_catalog.current_schema() AND c.relname = ${table}`,\n values: collector.values,\n returning: \"none\",\n };\n}\n\n/** Whether a live (non-dropped, non-system) column of that name exists on a table. */\nexport function renderColumnStateQuery(params: {\n dialect: SqlDialect;\n table: string;\n column: string;\n}): RenderedQuery {\n requirePostgres({ dialect: params.dialect, feature: \"renameRecovery\" });\n const collector = new ParamCollector(params.dialect);\n const table = collector.add(params.table);\n const column = collector.add(params.column);\n return {\n text: `SELECT a.attname::text AS \"column\"\nFROM pg_catalog.pg_attribute a\nJOIN pg_catalog.pg_class c ON c.oid = a.attrelid\nJOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\nWHERE n.nspname = pg_catalog.current_schema() AND c.relname = ${table} AND a.attname = ${column}\n AND a.attnum > 0 AND NOT a.attisdropped`,\n values: collector.values,\n returning: \"none\",\n };\n}\n"
72
73
  ],
73
- "mappings": ";;AAeA,IAAM,aAAa,IAAI;AAGvB,SAAS,YAAY,CAAC,QAAwD;AAAA,EAC5E,MAAM,WAAW,UAAU,KAAK,OAAO,IAAI,IAAI,MAAM;AAAA,EACrD,MAAM,YAAY,SAAS,MAAM,CAAC,EAAE,QAAQ,OAAO,EAAE;AAAA,EACrD,MAAM,YAAY,KAAK,UAAU,YAAY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