@prisma/orm-target-sqlite 8.0.0-rc.16-dev.6 → 8.0.0-rc.16-dev.8

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.
Files changed (69) hide show
  1. package/dist/{adapter-Cy1Xx1rP-CJcOoS_O.mjs → adapter-Cfp6xn4m-C6mXiIUR.mjs} +8 -11
  2. package/dist/adapter-Cfp6xn4m-C6mXiIUR.mjs.map +1 -0
  3. package/dist/adapter.mjs +2 -2
  4. package/dist/adapter__adapter.mjs +1 -1
  5. package/dist/adapter__control.mjs +3 -3
  6. package/dist/adapter__control.mjs.map +1 -1
  7. package/dist/adapter__runtime.mjs +1 -1
  8. package/dist/adapter__runtime.mjs.map +1 -1
  9. package/dist/adapter__sql-renderer.mjs +1 -1
  10. package/dist/{contract-free-CH8tBLLe.mjs → contract-free-CEPqytba.mjs} +2 -2
  11. package/dist/{contract-free-CH8tBLLe.mjs.map → contract-free-CEPqytba.mjs.map} +1 -1
  12. package/dist/{control-CtIPKwqL.mjs → control-L6vqj4xm.mjs} +6 -5
  13. package/dist/control-L6vqj4xm.mjs.map +1 -0
  14. package/dist/{ddl-CXduXyOT-nlDP6DGx.mjs → ddl-CDoa1Ehx-BOT670XL.mjs} +40 -3
  15. package/dist/ddl-CDoa1Ehx-BOT670XL.mjs.map +1 -0
  16. package/dist/{migration-Ccuxti02.d.mts → migration-CGyA6YVp.d.mts} +2 -2
  17. package/dist/{migration-Ccuxti02.d.mts.map → migration-CGyA6YVp.d.mts.map} +1 -1
  18. package/dist/{migration-65TwrHP0.mjs → migration-DNLfgvkg.mjs} +2 -2
  19. package/dist/{migration-65TwrHP0.mjs.map → migration-DNLfgvkg.mjs.map} +1 -1
  20. package/dist/{op-factory-call-B_WuATMN.d.mts → op-factory-call-BsGdsm8Y.d.mts} +57 -8
  21. package/dist/op-factory-call-BsGdsm8Y.d.mts.map +1 -0
  22. package/dist/{op-factory-call-Bwp3QS4h-MwflmSX3.mjs → op-factory-call-Cwsf4slr-DRGuq5SV.mjs} +136 -18
  23. package/dist/op-factory-call-Cwsf4slr-DRGuq5SV.mjs.map +1 -0
  24. package/dist/{planner-CFIbY54l.d.mts → planner-BOOV5W-E.d.mts} +16 -6
  25. package/dist/planner-BOOV5W-E.d.mts.map +1 -0
  26. package/dist/{planner-DcRJaFjk-C9iIWF69.mjs → planner-BWkNzmeL-BolB7hXm.mjs} +144 -16
  27. package/dist/planner-BWkNzmeL-BolB7hXm.mjs.map +1 -0
  28. package/dist/planner-produced-sqlite-migration-CBmtR7UQ.d.mts +1 -0
  29. package/dist/{planner-produced-sqlite-migration-DTTOgkuK-CppVPY1d.mjs → planner-produced-sqlite-migration-Da1JOGGe-Cibm7mK1.mjs} +4 -4
  30. package/dist/{planner-produced-sqlite-migration-DTTOgkuK-CppVPY1d.mjs.map → planner-produced-sqlite-migration-Da1JOGGe-Cibm7mK1.mjs.map} +1 -1
  31. package/dist/{planner-produced-sqlite-migration-DXcx0sOR-CcMQKE7n.d.mts → planner-produced-sqlite-migration-aUyGmguF-BORtY3yL.d.mts} +3 -3
  32. package/dist/planner-produced-sqlite-migration-aUyGmguF-BORtY3yL.d.mts.map +1 -0
  33. package/dist/{render-ops-KxAmAz6d-W2xyvA5y.mjs → render-ops-BfFXRHIV-x1i1WAHz.mjs} +16 -9
  34. package/dist/render-ops-BfFXRHIV-x1i1WAHz.mjs.map +1 -0
  35. package/dist/{sqlite-contract-view-BYR10usg-BteDAUZr.mjs → sqlite-contract-view-BrXalcTm-DYDH4LQC.mjs} +4 -3
  36. package/dist/sqlite-contract-view-BrXalcTm-DYDH4LQC.mjs.map +1 -0
  37. package/dist/{sqlite-migration-DckJS_3w-BIKXWN5h.mjs → sqlite-migration-Bz7SwolX-CHLtwGNa.mjs} +357 -62
  38. package/dist/sqlite-migration-Bz7SwolX-CHLtwGNa.mjs.map +1 -0
  39. package/dist/{sqlite-migration-BSUZhMDG-DZU3d7bZ.d.mts → sqlite-migration-Kqf6dAgP-DDc4wuXM.d.mts} +27 -3
  40. package/dist/sqlite-migration-Kqf6dAgP-DDc4wuXM.d.mts.map +1 -0
  41. package/dist/target.d.mts +7 -7
  42. package/dist/target.mjs +12 -12
  43. package/dist/target__contract-free.mjs +2 -2
  44. package/dist/target__control.mjs +2 -2
  45. package/dist/target__migration.d.mts +2 -2
  46. package/dist/target__migration.mjs +2 -2
  47. package/dist/target__op-factory-call.d.mts +2 -2
  48. package/dist/target__op-factory-call.mjs +2 -2
  49. package/dist/target__planner-produced-sqlite-migration.d.mts +2 -2
  50. package/dist/target__planner-produced-sqlite-migration.mjs +1 -1
  51. package/dist/target__planner.d.mts +1 -1
  52. package/dist/target__planner.mjs +1 -1
  53. package/dist/target__render-ops.mjs +1 -1
  54. package/dist/target__runtime.mjs +1 -1
  55. package/dist/target__runtime.mjs.map +1 -1
  56. package/package.json +9 -9
  57. package/dist/adapter-Cy1Xx1rP-CJcOoS_O.mjs.map +0 -1
  58. package/dist/control-CtIPKwqL.mjs.map +0 -1
  59. package/dist/ddl-CXduXyOT-nlDP6DGx.mjs.map +0 -1
  60. package/dist/op-factory-call-B_WuATMN.d.mts.map +0 -1
  61. package/dist/op-factory-call-Bwp3QS4h-MwflmSX3.mjs.map +0 -1
  62. package/dist/planner-CFIbY54l.d.mts.map +0 -1
  63. package/dist/planner-DcRJaFjk-C9iIWF69.mjs.map +0 -1
  64. package/dist/planner-produced-sqlite-migration-DXcx0sOR-CcMQKE7n.d.mts.map +0 -1
  65. package/dist/planner-produced-sqlite-migration-sYbbeyyS.d.mts +0 -1
  66. package/dist/render-ops-KxAmAz6d-W2xyvA5y.mjs.map +0 -1
  67. package/dist/sqlite-contract-view-BYR10usg-BteDAUZr.mjs.map +0 -1
  68. package/dist/sqlite-migration-BSUZhMDG-DZU3d7bZ.d.mts.map +0 -1
  69. package/dist/sqlite-migration-DckJS_3w-BIKXWN5h.mjs.map +0 -1
@@ -1,5 +1,5 @@
1
1
  import { t as Op } from "./tables-CvLOKCiJ-Ca1eFkWN.mjs";
2
- import "./sqlite-migration-BSUZhMDG-DZU3d7bZ.mjs";
2
+ import "./sqlite-migration-Kqf6dAgP-DDc4wuXM.mjs";
3
3
  import { col as col$1, fn as fn$1, foreignKey, lit as lit$1, primaryKey, unique } from "@prisma/orm-family-sql/relational-core/contract-free";
4
4
  import { placeholder } from "@prisma/orm-framework/errors/migration";
5
5
  import { MigrationCLI } from "@prisma/orm-toolchain/cli/migration-cli";
@@ -40,4 +40,4 @@ declare function dataTransform(opts: DataTransformOptions): Op;
40
40
  declare function rawSql(op: Op): Op;
41
41
  //#endregion
42
42
  export { fn$1 as a, placeholder as c, unique as d, dataTransform as i, primaryKey as l, MigrationCLI as n, foreignKey as o, col$1 as r, lit$1 as s, DataTransformOptions as t, rawSql as u };
43
- //# sourceMappingURL=migration-Ccuxti02.d.mts.map
43
+ //# sourceMappingURL=migration-CGyA6YVp.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"migration-Ccuxti02.d.mts","names":[],"sources":["../../../../3-targets/3-targets/sqlite/dist/migration.d.mts"],"mappings":";;;;;;;UAMU;;WAEC;;WAEA;;WAEA;;;;;WAKA;;;;;;;;;WASA;;iBAEM,cAAc,MAAM,uBAAuB;;;;;;;;;;iBAU3C,OAAO,IAAI,KAAK"}
1
+ {"version":3,"file":"migration-CGyA6YVp.d.mts","names":[],"sources":["../../../../3-targets/3-targets/sqlite/dist/migration.d.mts"],"mappings":";;;;;;;UAMU;;WAEC;;WAEA;;WAEA;;;;;WAKA;;;;;;;;;WASA;;iBAEM,cAAc,MAAM,uBAAuB;;;;;;;;;;iBAU3C,OAAO,IAAI,KAAK"}
@@ -1,5 +1,5 @@
1
1
  import { t as buildTargetDetails } from "./planner-target-details-CIQ789Gc-C5U4yVY9.mjs";
2
- import { v as step } from "./op-factory-call-Bwp3QS4h-MwflmSX3.mjs";
2
+ import { x as step } from "./op-factory-call-Cwsf4slr-DRGuq5SV.mjs";
3
3
  import { col as col$1, fn as fn$1, foreignKey, lit as lit$1, primaryKey, unique } from "@prisma/orm-family-sql/relational-core/contract-free";
4
4
  import { placeholder } from "@prisma/orm-framework/errors/migration";
5
5
  import { MigrationCLI } from "@prisma/orm-toolchain/cli/migration-cli";
@@ -44,4 +44,4 @@ function rawSql(op) {
44
44
  //#endregion
45
45
  export { foreignKey as a, primaryKey as c, fn$1 as i, rawSql as l, col$1 as n, lit$1 as o, dataTransform as r, placeholder as s, MigrationCLI as t, unique as u };
46
46
 
47
- //# sourceMappingURL=migration-65TwrHP0.mjs.map
47
+ //# sourceMappingURL=migration-DNLfgvkg.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"migration-65TwrHP0.mjs","names":[],"sources":["../../../../3-targets/3-targets/sqlite/dist/migration.mjs"],"sourcesContent":["import { h as step } from \"./op-factory-call-Bwp3QS4h.mjs\";\nimport { t as SqliteMigration } from \"./sqlite-migration-DckJS_3w.mjs\";\nimport { t as buildTargetDetails } from \"./planner-target-details-CIQ789Gc.mjs\";\nimport { placeholder } from \"@internal/errors/migration\";\nimport { col, fn, foreignKey, lit, primaryKey, unique } from \"@internal/sql-relational-core/contract-free\";\nimport { MigrationCLI } from \"@internal/cli/migration-cli\";\n//#region src/core/migrations/operations/data-transform.ts\n/**\n* User-facing `dataTransform` factory for the SQLite migration authoring\n* surface. Invoked directly inside a `migration.ts` file to supply a\n* user-authored SQL statement that runs with operation class `'data'`.\n*\n* Typical use: the planner emits a `DataTransformCall` stub when a NOT NULL\n* tightening requires a backfill. The rendered `migration.ts` exposes the\n* backfill as a `placeholder(\"…\")` slot the user fills in with an\n* `UPDATE … WHERE col IS NULL` statement. The filled-in `dataTransform(...)`\n* invocation returns a runnable operation the runner executes before the\n* subsequent recreate-table op copies data into the tightened schema.\n*/\nfunction dataTransform(opts) {\n\treturn {\n\t\tid: opts.id,\n\t\tlabel: opts.label,\n\t\tsummary: opts.description,\n\t\toperationClass: \"data\",\n\t\ttarget: {\n\t\t\tid: \"sqlite\",\n\t\t\tdetails: buildTargetDetails(\"table\", opts.table)\n\t\t},\n\t\tprecheck: [],\n\t\texecute: [step(opts.description, opts.run())],\n\t\tpostcheck: []\n\t};\n}\n//#endregion\n//#region src/core/migrations/operations/raw.ts\n/**\n* Identity factory for an already-materialized\n* `SqlMigrationPlanOperation<SqlitePlanTargetDetails>`. Mirrors the Postgres\n* `rawSql` factory: the planner uses this to carry ops produced by SQL-family\n* paths (codec lifecycle hooks, raw-SQL escape hatches) alongside structured\n* call IR without reverse-engineering their shape.\n*/\nfunction rawSql(op) {\n\treturn op;\n}\n//#endregion\nexport { SqliteMigration as Migration, MigrationCLI, col, dataTransform, fn, foreignKey, lit, placeholder, primaryKey, rawSql, unique };\n\n//# sourceMappingURL=migration.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;AAmBA,SAAS,cAAc,MAAM;CAC5B,OAAO;EACN,IAAI,KAAK;EACT,OAAO,KAAK;EACZ,SAAS,KAAK;EACd,gBAAgB;EAChB,QAAQ;GACP,IAAI;GACJ,SAAS,mBAAmB,SAAS,KAAK,KAAK;EAChD;EACA,UAAU,CAAC;EACX,SAAS,CAAC,KAAK,KAAK,aAAa,KAAK,IAAI,CAAC,CAAC;EAC5C,WAAW,CAAC;CACb;AACD;;;;;;;;AAUA,SAAS,OAAO,IAAI;CACnB,OAAO;AACR"}
1
+ {"version":3,"file":"migration-DNLfgvkg.mjs","names":[],"sources":["../../../../3-targets/3-targets/sqlite/dist/migration.mjs"],"sourcesContent":["import { v as step } from \"./op-factory-call-Cwsf4slr.mjs\";\nimport { t as SqliteMigration } from \"./sqlite-migration-Bz7SwolX.mjs\";\nimport { t as buildTargetDetails } from \"./planner-target-details-CIQ789Gc.mjs\";\nimport { placeholder } from \"@internal/errors/migration\";\nimport { col, fn, foreignKey, lit, primaryKey, unique } from \"@internal/sql-relational-core/contract-free\";\nimport { MigrationCLI } from \"@internal/cli/migration-cli\";\n//#region src/core/migrations/operations/data-transform.ts\n/**\n* User-facing `dataTransform` factory for the SQLite migration authoring\n* surface. Invoked directly inside a `migration.ts` file to supply a\n* user-authored SQL statement that runs with operation class `'data'`.\n*\n* Typical use: the planner emits a `DataTransformCall` stub when a NOT NULL\n* tightening requires a backfill. The rendered `migration.ts` exposes the\n* backfill as a `placeholder(\"…\")` slot the user fills in with an\n* `UPDATE … WHERE col IS NULL` statement. The filled-in `dataTransform(...)`\n* invocation returns a runnable operation the runner executes before the\n* subsequent recreate-table op copies data into the tightened schema.\n*/\nfunction dataTransform(opts) {\n\treturn {\n\t\tid: opts.id,\n\t\tlabel: opts.label,\n\t\tsummary: opts.description,\n\t\toperationClass: \"data\",\n\t\ttarget: {\n\t\t\tid: \"sqlite\",\n\t\t\tdetails: buildTargetDetails(\"table\", opts.table)\n\t\t},\n\t\tprecheck: [],\n\t\texecute: [step(opts.description, opts.run())],\n\t\tpostcheck: []\n\t};\n}\n//#endregion\n//#region src/core/migrations/operations/raw.ts\n/**\n* Identity factory for an already-materialized\n* `SqlMigrationPlanOperation<SqlitePlanTargetDetails>`. Mirrors the Postgres\n* `rawSql` factory: the planner uses this to carry ops produced by SQL-family\n* paths (codec lifecycle hooks, raw-SQL escape hatches) alongside structured\n* call IR without reverse-engineering their shape.\n*/\nfunction rawSql(op) {\n\treturn op;\n}\n//#endregion\nexport { SqliteMigration as Migration, MigrationCLI, col, dataTransform, fn, foreignKey, lit, placeholder, primaryKey, rawSql, unique };\n\n//# sourceMappingURL=migration.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;AAmBA,SAAS,cAAc,MAAM;CAC5B,OAAO;EACN,IAAI,KAAK;EACT,OAAO,KAAK;EACZ,SAAS,KAAK;EACd,gBAAgB;EAChB,QAAQ;GACP,IAAI;GACJ,SAAS,mBAAmB,SAAS,KAAK,KAAK;EAChD;EACA,UAAU,CAAC;EACX,SAAS,CAAC,KAAK,KAAK,aAAa,KAAK,IAAI,CAAC,CAAC;EAC5C,WAAW,CAAC;CACb;AACD;;;;;;;;AAUA,SAAS,OAAO,IAAI;CACnB,OAAO;AACR"}
@@ -13,6 +13,8 @@ declare abstract class SqliteOpFactoryCallNode extends TsExpression implements O
13
13
  abstract readonly operationClass: MigrationOperationClass;
14
14
  abstract readonly label: string;
15
15
  abstract toOp(lowerer?: Lowerer): Op | Promise<Op>;
16
+ /** The operations this call lowers to, in order: one, unless the call carries companions. */
17
+ toOps(lowerer?: ExecuteRequestLowerer): readonly (Op | Promise<Op>)[];
16
18
  importRequirements(): readonly ImportRequirement[];
17
19
  protected freeze(): void;
18
20
  }
@@ -38,6 +40,13 @@ declare class DropTableCall extends SqliteOpFactoryCallNode {
38
40
  renderTypeScript(): string;
39
41
  importRequirements(): readonly ImportRequirement[];
40
42
  }
43
+ /** An index SQLite cannot rename, dropped and created again under its new name. */
44
+ interface IndexReplacement {
45
+ readonly drop: DropIndexCall;
46
+ readonly create: CreateIndexCall;
47
+ }
48
+ /** A call a table or column rename carries to replace an index whose name derives from the old name. */
49
+ type RenameCompanionCall = DropIndexCall | CreateIndexCall;
41
50
  declare class RenameTableCall extends SqliteOpFactoryCallNode {
42
51
  readonly factoryName: "renameTable";
43
52
  readonly operationClass: "widening";
@@ -45,7 +54,38 @@ declare class RenameTableCall extends SqliteOpFactoryCallNode {
45
54
  /** The new name: the table's contract-side identity after the rename. */
46
55
  readonly tableName: string;
47
56
  readonly label: string;
48
- constructor(oldTableName: string, tableName: string);
57
+ /** The indexes named after the old table, which SQLite cannot rename, so it replaces them. */
58
+ readonly indexReplacements: readonly IndexReplacement[];
59
+ /**
60
+ * The replacements' drops, then their creates. They run after the table rename and are never
61
+ * rendered on their own.
62
+ */
63
+ readonly companions: readonly RenameCompanionCall[];
64
+ constructor(oldTableName: string, tableName: string, indexReplacements: readonly IndexReplacement[]);
65
+ /** The id of the operation this call lowers to. */
66
+ get operationId(): string;
67
+ toOps(lowerer?: ExecuteRequestLowerer): readonly Promise<Op>[];
68
+ toOp(lowerer?: ExecuteRequestLowerer): Promise<Op>;
69
+ renderTypeScript(): string;
70
+ importRequirements(): readonly ImportRequirement[];
71
+ }
72
+ declare class RenameColumnCall extends SqliteOpFactoryCallNode {
73
+ readonly factoryName: "renameColumn";
74
+ readonly operationClass: "widening";
75
+ readonly tableName: string;
76
+ readonly oldColumnName: string;
77
+ /** The new name: the column's contract-side identity after the rename. */
78
+ readonly columnName: string;
79
+ readonly label: string;
80
+ /** The indexes on the column whose wire names change, which SQLite cannot rename. */
81
+ readonly indexReplacements: readonly IndexReplacement[];
82
+ /**
83
+ * The replacements' drops, then their creates. They run after the column rename and are never
84
+ * rendered on their own.
85
+ */
86
+ readonly companions: readonly RenameCompanionCall[];
87
+ constructor(tableName: string, oldColumnName: string, columnName: string, indexReplacements: readonly IndexReplacement[]);
88
+ toOps(lowerer?: ExecuteRequestLowerer): readonly Promise<Op>[];
49
89
  toOp(lowerer?: ExecuteRequestLowerer): Promise<Op>;
50
90
  renderTypeScript(): string;
51
91
  importRequirements(): readonly ImportRequirement[];
@@ -60,6 +100,11 @@ declare class RecreateTableCall extends SqliteOpFactoryCallNode {
60
100
  readonly summary: string;
61
101
  readonly postchecks: readonly RecreatePostcheck[];
62
102
  readonly label: string;
103
+ /**
104
+ * The columns whose values the copy can change, because their type changes. The planner reads
105
+ * them to name what the recreate loses; they never reach the operation or `migration.ts`.
106
+ */
107
+ readonly lossyColumns: readonly string[];
63
108
  constructor(args: {
64
109
  tableName: string;
65
110
  contractTable: SqliteTableSpec;
@@ -68,7 +113,7 @@ declare class RecreateTableCall extends SqliteOpFactoryCallNode {
68
113
  summary: string;
69
114
  postchecks: readonly RecreatePostcheck[];
70
115
  operationClass: MigrationOperationClass;
71
- });
116
+ }, lossyColumns?: readonly string[]);
72
117
  toOp(lowerer?: ExecuteRequestLowerer): Promise<Op>;
73
118
  renderTypeScript(): string;
74
119
  importRequirements(): readonly ImportRequirement[];
@@ -104,17 +149,21 @@ declare class CreateIndexCall extends SqliteOpFactoryCallNode {
104
149
  readonly columns: readonly string[];
105
150
  readonly label: string;
106
151
  constructor(tableName: string, indexName: string, columns: readonly string[]);
152
+ /** The id of the operation this call lowers to. */
153
+ get operationId(): string;
107
154
  toOp(lowerer?: ExecuteRequestLowerer): Promise<Op>;
108
155
  renderTypeScript(): string;
109
156
  importRequirements(): readonly ImportRequirement[];
110
157
  }
111
158
  declare class DropIndexCall extends SqliteOpFactoryCallNode {
112
159
  readonly factoryName: "dropIndex";
113
- readonly operationClass: "destructive";
160
+ readonly operationClass: "widening";
114
161
  readonly tableName: string;
115
162
  readonly indexName: string;
116
163
  readonly label: string;
117
164
  constructor(tableName: string, indexName: string);
165
+ /** The id of the operation this call lowers to. */
166
+ get operationId(): string;
118
167
  toOp(lowerer?: ExecuteRequestLowerer): Promise<Op>;
119
168
  renderTypeScript(): string;
120
169
  importRequirements(): readonly ImportRequirement[];
@@ -127,7 +176,7 @@ declare class DropIndexCall extends SqliteOpFactoryCallNode {
127
176
  * any future strategy that needs a placeholder data step can construct one
128
177
  * with its own id/label.
129
178
  *
130
- * `toOp()` always throws `MIGRATION.UNFILLED_PLACEHOLDER`: the planner cannot lower a stubbed
179
+ * `toOp()` always rejects with `MIGRATION.UNFILLED_PLACEHOLDER`: the planner cannot lower a stubbed
131
180
  * transform to a runtime op — the user must edit the rendered
132
181
  * `migration.ts` and re-emit.
133
182
  */
@@ -139,7 +188,7 @@ declare class DataTransformCall extends SqliteOpFactoryCallNode {
139
188
  readonly tableName: string;
140
189
  readonly columnName: string;
141
190
  constructor(id: string, label: string, tableName: string, columnName: string);
142
- toOp(_lowerer?: Lowerer): Op;
191
+ toOp(_lowerer?: Lowerer): Promise<Op>;
143
192
  renderTypeScript(): string;
144
193
  importRequirements(): readonly ImportRequirement[];
145
194
  }
@@ -161,7 +210,7 @@ declare class RawSqlCall extends SqliteOpFactoryCallNode {
161
210
  toOp(_lowerer?: Lowerer): Op;
162
211
  renderTypeScript(): string;
163
212
  }
164
- type SqliteOpFactoryCall = CreateTableCall | DropTableCall | RecreateTableCall | RenameTableCall | AddColumnCall | DropColumnCall | CreateIndexCall | DropIndexCall | DataTransformCall | RawSqlCall;
213
+ type SqliteOpFactoryCall = CreateTableCall | DropTableCall | RecreateTableCall | RenameTableCall | RenameColumnCall | AddColumnCall | DropColumnCall | CreateIndexCall | DropIndexCall | DataTransformCall | RawSqlCall;
165
214
  //#endregion
166
- export { DropColumnCall as a, RawSqlCall as c, SqliteOpFactoryCall as d, DataTransformCall as i, RecreateTableCall as l, CreateIndexCall as n, DropIndexCall as o, CreateTableCall as r, DropTableCall as s, AddColumnCall as t, RenameTableCall as u };
167
- //# sourceMappingURL=op-factory-call-B_WuATMN.d.mts.map
215
+ export { DropColumnCall as a, RawSqlCall as c, RenameTableCall as d, SqliteOpFactoryCall as f, DataTransformCall as i, RecreateTableCall as l, CreateIndexCall as n, DropIndexCall as o, CreateTableCall as r, DropTableCall as s, AddColumnCall as t, RenameColumnCall as u };
216
+ //# sourceMappingURL=op-factory-call-BsGdsm8Y.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"op-factory-call-BsGdsm8Y.d.mts","names":[],"sources":["../../../../3-targets/3-targets/sqlite/dist/op-factory-call.d.mts"],"mappings":";;;;;;;;;KAQK,KAAK,0BAA0B;uBACb,gCAAgC,wBAAwB;oBAC3D;oBACA,gBAAgB;oBAChB;WACT,KAAK,UAAU,UAAU,KAAK,QAAQ;;EAE/C,MAAM,UAAU,kCAAkC,KAAK,QAAQ;EAC/D,+BAA+B;YACrB;;cAEE,wBAAwB;WAC3B;WACA;WACA;WACA,kBAAkB;WAClB,sBAAsB;WACtB;EACT,YAAY,mBAAmB,kBAAkB,aAAa,uBAAuB;EACrF,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,sBAAsB;WACzB;WACA;WACA;WACA;EACT,YAAY;EACZ,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;;UAGvB;WACC,MAAM;WACN,QAAQ;;;KAGd,sBAAsB,gBAAgB;cAC7B,wBAAwB;WAC3B;WACA;WACA;;WAEA;WACA;;WAEA,4BAA4B;;;;;WAK5B,qBAAqB;EAC9B,YAAY,sBAAsB,mBAAmB,4BAA4B;;MAE7E;EACJ,MAAM,UAAU,iCAAiC,QAAQ;EACzD,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,yBAAyB;WAC5B;WACA;WACA;WACA;;WAEA;WACA;;WAEA,4BAA4B;;;;;WAK5B,qBAAqB;EAC9B,YAAY,mBAAmB,uBAAuB,oBAAoB,4BAA4B;EACtG,MAAM,UAAU,iCAAiC,QAAQ;EACzD,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,0BAA0B;WAC7B;WACA,gBAAgB;WAChB;WACA,eAAe;WACf;WACA,kBAAkB;WAClB;WACA,qBAAqB;WACrB;;;;;WAKA;EACT,YAAY;IACV;IACA,eAAe;IACf;IACA,kBAAkB;IAClB;IACA,qBAAqB;IACrB,gBAAgB;KACf;EACH,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,sBAAsB;WACzB;WACA;WACA;WACA;WACA,QAAQ;WACR;EACT,YAAY,mBAAmB,QAAQ;EACvC,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,uBAAuB;WAC1B;WACA;WACA;WACA;WACA;EACT,YAAY,mBAAmB;EAC/B,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,wBAAwB;WAC3B;WACA;WACA;WACA;WACA;WACA;EACT,YAAY,mBAAmB,mBAAmB;;MAE9C;EACJ,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;cAEnB,sBAAsB;WACzB;WACA;WACA;WACA;WACA;EACT,YAAY,mBAAmB;;MAE3B;EACJ,KAAK,UAAU,wBAAwB,QAAQ;EAC/C;EACA,+BAA+B;;;;;;;;;;;;;;cAcnB,0BAA0B;WAC7B;WACA;WACA;WACA;WACA;WACA;EACT,YAAY,YAAY,eAAe,mBAAmB;EAC1D,KAAK,WAAW,UAAU,QAAQ;EAClC;EACA,+BAA+B;;;;;;;;;;;cAWnB,mBAAmB;WACtB;WACA,gBAAgB;WAChB;WACA,IAAI;EACb,YAAY,IAAI;EAChB,KAAK,WAAW,UAAU;EAC1B;;KAEG,sBAAsB,kBAAkB,gBAAgB,oBAAoB,kBAAkB,mBAAmB,gBAAgB,iBAAiB,kBAAkB,gBAAgB,oBAAoB"}
@@ -1,9 +1,9 @@
1
1
  import { o as sqliteInteger } from "./data-types-pFQMl37_-B-3aK_wd.mjs";
2
2
  import { n as sqliteError } from "./errors-DnR-sMHS-KkMLIP2U.mjs";
3
3
  import { n as decodeSqliteDatetime, r as encodeSqliteDatetime } from "./codecs-BctEWIFt-DgMd3dUl.mjs";
4
- import { i as tableExistsAst, n as createTable, r as indexExistsAst, t as columnExistsAst } from "./ddl-CXduXyOT-nlDP6DGx.mjs";
5
- import { r as stripOuterParens } from "./default-normalizer-Ch3VFnEH-C-h1XtlJ.mjs";
4
+ import { a as tableExistsAst, i as indexExistsAst, n as columnNameTakenAst, o as tableNameTakenAst, r as createTable, t as columnExistsAst } from "./ddl-CDoa1Ehx-BOT670XL.mjs";
6
5
  import { n as quoteIdentifier, t as escapeLiteral } from "./sql-utils-C2O4zVkP-Dz3Hb85I.mjs";
6
+ import { r as stripOuterParens } from "./default-normalizer-Ch3VFnEH-C-h1XtlJ.mjs";
7
7
  import { t as buildTargetDetails } from "./planner-target-details-CIQ789Gc-C5U4yVY9.mjs";
8
8
  import { DdlColumn, FunctionColumnDefault, LiteralColumnDefault, opaqueSql } from "@prisma/orm-family-sql/relational-core/ast";
9
9
  import { ifDefined } from "@prisma/orm-framework/utils/defined";
@@ -12,10 +12,10 @@ import { dataTypeParams, renderSqlTypeName, sqlDataTypeOfCodec } from "@prisma/o
12
12
  import { issueOutcome } from "@prisma/orm-framework/components/control";
13
13
  import { RelationalSchemaNodeKind } from "@prisma/orm-family-sql/schema-ir/types";
14
14
  import { assertNever } from "@prisma/orm-framework/utils/internal-error";
15
- import { errorMigrationOperationOptionRemoved, errorUnfilledPlaceholder } from "@prisma/orm-framework/errors/migration";
15
+ import { errorMigrationOperationOptionRemoved, unfilledPlaceholderOperation } from "@prisma/orm-framework/errors/migration";
16
16
  import { REFERENTIAL_ACTION_SQL } from "@prisma/orm-family-sql/contract/referential-action-sql";
17
17
  import { TsExpression, jsonToTsSource, tsArraySource, tsObjectSource, tsQuotedTextSource } from "@prisma/orm-framework/ts-render";
18
- //#region ../../../3-targets/3-targets/sqlite/dist/op-factory-call-Bwp3QS4h.mjs
18
+ //#region ../../../3-targets/3-targets/sqlite/dist/op-factory-call-Cwsf4slr.mjs
19
19
  /**
20
20
  * Low-level DDL fragment builders for SQLite migrations.
21
21
  *
@@ -178,6 +178,39 @@ async function addColumn(tableName, column, lowerer) {
178
178
  postcheck: [step(`verify column "${column.name}" exists`, present.sql, present.params)]
179
179
  };
180
180
  }
181
+ function renameColumnExecuteSql(tableName, fromName, toName) {
182
+ return `ALTER TABLE ${quoteIdentifier(tableName)} RENAME COLUMN ${quoteIdentifier(fromName)} TO ${quoteIdentifier(toName)}`;
183
+ }
184
+ /**
185
+ * Renames a column. SQLite updates the indexes, foreign keys and triggers that name it, and keeps
186
+ * index names. SQLite takes names that differ only in case for the same name, so the new name
187
+ * must be free whatever its case, except in a rename that only changes case, which SQLite performs
188
+ * in one statement.
189
+ */
190
+ function renameColumnOperationId(tableName, fromName) {
191
+ return `renameColumn.${tableName}.${fromName}`;
192
+ }
193
+ async function renameColumn(tableName, fromName, toName, lowerer) {
194
+ const fromChecks = columnExistsAst(tableName, fromName);
195
+ const toChecks = columnExistsAst(tableName, toName);
196
+ const fromPresent = await lowerer.lowerToExecuteRequest(fromChecks.columnPresent());
197
+ const toAbsent = await lowerer.lowerToExecuteRequest(sqliteIdentifiersCollide(fromName, toName) ? toChecks.columnAbsent() : columnNameTakenAst(tableName, toName).nameFree());
198
+ const toPresent = await lowerer.lowerToExecuteRequest(toChecks.columnPresent());
199
+ const fromAbsent = await lowerer.lowerToExecuteRequest(fromChecks.columnAbsent());
200
+ return {
201
+ id: renameColumnOperationId(tableName, fromName),
202
+ label: `Rename column ${fromName} on ${tableName} to ${toName}`,
203
+ summary: `Renames column ${fromName} on ${tableName} to ${toName}, keeping its values`,
204
+ operationClass: "widening",
205
+ target: {
206
+ id: "sqlite",
207
+ details: buildTargetDetails("column", toName, tableName)
208
+ },
209
+ precheck: [step(`ensure column "${fromName}" exists on "${tableName}"`, fromPresent.sql, fromPresent.params), step(`ensure column "${toName}" does not exist on "${tableName}"`, toAbsent.sql, toAbsent.params)],
210
+ execute: [step(`rename column "${fromName}" on "${tableName}" to "${toName}"`, renameColumnExecuteSql(tableName, fromName, toName))],
211
+ postcheck: [step(`verify column "${toName}" exists on "${tableName}"`, toPresent.sql, toPresent.params), step(`verify column "${fromName}" no longer exists on "${tableName}"`, fromAbsent.sql, fromAbsent.params)]
212
+ };
213
+ }
181
214
  async function tableExistsSteps(lowerer, tableName) {
182
215
  const checks = tableExistsAst(tableName);
183
216
  return {
@@ -451,6 +484,10 @@ function buildRecreatePostchecks(tableName, issues, spec) {
451
484
  }
452
485
  const TARGET_MIGRATION_MODULE = "@internal/sqlite/migration";
453
486
  var SqliteOpFactoryCallNode = class extends TsExpression {
487
+ /** The operations this call lowers to, in order: one, unless the call carries companions. */
488
+ toOps(lowerer) {
489
+ return [this.toOp(lowerer)];
490
+ }
454
491
  importRequirements() {
455
492
  return [{
456
493
  moduleSpecifier: TARGET_MIGRATION_MODULE,
@@ -461,6 +498,10 @@ var SqliteOpFactoryCallNode = class extends TsExpression {
461
498
  Object.freeze(this);
462
499
  }
463
500
  };
501
+ /** Whether `call` is one of this target's calls, which lower through {@link SqliteOpFactoryCallNode.toOps}. */
502
+ function isSqliteOpFactoryCall(call) {
503
+ return call instanceof SqliteOpFactoryCallNode;
504
+ }
464
505
  function renderDdlColumnDefault(def) {
465
506
  if (!def) return "";
466
507
  if (def.kind === "literal") return `lit(${jsonToTsSource(def.value)})`;
@@ -626,6 +667,10 @@ var DropTableCall = class extends SqliteOpFactoryCallNode {
626
667
  return [];
627
668
  }
628
669
  };
670
+ /** The replaced indexes' drops, then their creates, since a create may take a dropped name. */
671
+ function indexReplacementCalls(replacements) {
672
+ return [...replacements.map(({ drop }) => drop), ...replacements.map(({ create }) => create)];
673
+ }
629
674
  var RenameTableCall = class extends SqliteOpFactoryCallNode {
630
675
  factoryName = "renameTable";
631
676
  operationClass = "widening";
@@ -633,13 +678,29 @@ var RenameTableCall = class extends SqliteOpFactoryCallNode {
633
678
  /** The new name: the table's contract-side identity after the rename. */
634
679
  tableName;
635
680
  label;
636
- constructor(oldTableName, tableName) {
681
+ /** The indexes named after the old table, which SQLite cannot rename, so it replaces them. */
682
+ indexReplacements;
683
+ /**
684
+ * The replacements' drops, then their creates. They run after the table rename and are never
685
+ * rendered on their own.
686
+ */
687
+ companions;
688
+ constructor(oldTableName, tableName, indexReplacements) {
637
689
  super();
638
690
  this.oldTableName = oldTableName;
639
691
  this.tableName = tableName;
640
692
  this.label = `Rename table ${oldTableName} to ${tableName}`;
693
+ this.indexReplacements = Object.freeze([...indexReplacements]);
694
+ this.companions = Object.freeze(indexReplacementCalls(indexReplacements));
641
695
  this.freeze();
642
696
  }
697
+ /** The id of the operation this call lowers to. */
698
+ get operationId() {
699
+ return `renameTable.${this.oldTableName}`;
700
+ }
701
+ toOps(lowerer) {
702
+ return [this.toOp(lowerer), ...this.companions.map((companion) => companion.toOp(lowerer))];
703
+ }
643
704
  async toOp(lowerer) {
644
705
  if (lowerer === void 0) throw sqliteError("MIGRATION.SQLITE_CONTROL_STACK_MISSING", `RenameTableCall.toOp: a lowerer is required on the SQLite planner path (table "${this.oldTableName}"). Pass the control adapter to createSqliteMigrationPlanner.`, { meta: {
645
706
  factory: this.factoryName,
@@ -648,13 +709,14 @@ var RenameTableCall = class extends SqliteOpFactoryCallNode {
648
709
  const fromChecks = tableExistsAst(this.oldTableName);
649
710
  const toChecks = tableExistsAst(this.tableName);
650
711
  const fromPresent = await lowerer.lowerToExecuteRequest(fromChecks.tablePresent());
651
- const toAbsent = await lowerer.lowerToExecuteRequest(toChecks.tableAbsent());
712
+ const onlyCase = renameChangesOnlyCase(this.oldTableName, this.tableName);
713
+ const toAbsent = await lowerer.lowerToExecuteRequest(onlyCase ? toChecks.tableAbsent() : tableNameTakenAst(this.tableName).nameFree());
652
714
  const viaName = renameTableViaName(this.tableName);
653
- const viaAbsent = renameChangesOnlyCase(this.oldTableName, this.tableName) ? await lowerer.lowerToExecuteRequest(tableExistsAst(viaName).tableAbsent()) : void 0;
715
+ const viaAbsent = onlyCase ? await lowerer.lowerToExecuteRequest(tableExistsAst(viaName).tableAbsent()) : void 0;
654
716
  const toPresent = await lowerer.lowerToExecuteRequest(toChecks.tablePresent());
655
717
  const fromAbsent = await lowerer.lowerToExecuteRequest(fromChecks.tableAbsent());
656
718
  return {
657
- id: `renameTable.${this.oldTableName}`,
719
+ id: this.operationId,
658
720
  label: this.label,
659
721
  summary: `Renames table ${this.oldTableName} to ${this.tableName}, keeping its rows`,
660
722
  operationClass: "widening",
@@ -664,7 +726,7 @@ var RenameTableCall = class extends SqliteOpFactoryCallNode {
664
726
  },
665
727
  precheck: [
666
728
  step(`ensure table "${this.oldTableName}" exists`, fromPresent.sql, fromPresent.params),
667
- step(`ensure table "${this.tableName}" does not exist`, toAbsent.sql, toAbsent.params),
729
+ step(onlyCase ? `ensure table "${this.tableName}" does not exist` : `ensure no table or index is named "${this.tableName}" in any case`, toAbsent.sql, toAbsent.params),
668
730
  ...viaAbsent === void 0 ? [] : [step(`ensure table "${viaName}" does not exist (a rename that only changes case passes through this temporary name, because SQLite compares table names without case)`, viaAbsent.sql, viaAbsent.params)]
669
731
  ],
670
732
  execute: renameTableSteps(this.oldTableName, this.tableName),
@@ -678,6 +740,48 @@ var RenameTableCall = class extends SqliteOpFactoryCallNode {
678
740
  return [];
679
741
  }
680
742
  };
743
+ var RenameColumnCall = class extends SqliteOpFactoryCallNode {
744
+ factoryName = "renameColumn";
745
+ operationClass = "widening";
746
+ tableName;
747
+ oldColumnName;
748
+ /** The new name: the column's contract-side identity after the rename. */
749
+ columnName;
750
+ label;
751
+ /** The indexes on the column whose wire names change, which SQLite cannot rename. */
752
+ indexReplacements;
753
+ /**
754
+ * The replacements' drops, then their creates. They run after the column rename and are never
755
+ * rendered on their own.
756
+ */
757
+ companions;
758
+ constructor(tableName, oldColumnName, columnName, indexReplacements) {
759
+ super();
760
+ this.tableName = tableName;
761
+ this.oldColumnName = oldColumnName;
762
+ this.columnName = columnName;
763
+ this.label = `Rename column ${oldColumnName} on ${tableName} to ${columnName}`;
764
+ this.indexReplacements = Object.freeze([...indexReplacements]);
765
+ this.companions = Object.freeze(indexReplacementCalls(indexReplacements));
766
+ this.freeze();
767
+ }
768
+ toOps(lowerer) {
769
+ return [this.toOp(lowerer), ...this.companions.map((companion) => companion.toOp(lowerer))];
770
+ }
771
+ async toOp(lowerer) {
772
+ if (lowerer === void 0) throw sqliteError("MIGRATION.SQLITE_CONTROL_STACK_MISSING", `RenameColumnCall.toOp: a lowerer is required on the SQLite planner path (column "${this.oldColumnName}" on table "${this.tableName}"). Pass the control adapter to createSqliteMigrationPlanner.`, { meta: {
773
+ factory: this.factoryName,
774
+ tableName: this.tableName
775
+ } });
776
+ return renameColumn(this.tableName, this.oldColumnName, this.columnName, lowerer);
777
+ }
778
+ renderTypeScript() {
779
+ return `...this.renameColumn({ table: ${jsonToTsSource(this.tableName)}, column: ${jsonToTsSource(this.oldColumnName)}, to: ${jsonToTsSource(this.columnName)} })`;
780
+ }
781
+ importRequirements() {
782
+ return [];
783
+ }
784
+ };
681
785
  var RecreateTableCall = class extends SqliteOpFactoryCallNode {
682
786
  factoryName = "recreateTable";
683
787
  operationClass;
@@ -688,8 +792,14 @@ var RecreateTableCall = class extends SqliteOpFactoryCallNode {
688
792
  summary;
689
793
  postchecks;
690
794
  label;
691
- constructor(args) {
795
+ /**
796
+ * The columns whose values the copy can change, because their type changes. The planner reads
797
+ * them to name what the recreate loses; they never reach the operation or `migration.ts`.
798
+ */
799
+ lossyColumns;
800
+ constructor(args, lossyColumns = []) {
692
801
  super();
802
+ this.lossyColumns = Object.freeze([...lossyColumns]);
693
803
  this.tableName = args.tableName;
694
804
  this.contractTable = args.contractTable;
695
805
  this.schemaColumnNames = args.schemaColumnNames;
@@ -818,6 +928,10 @@ var CreateIndexCall = class extends SqliteOpFactoryCallNode {
818
928
  this.label = `Create index ${indexName} on ${tableName}`;
819
929
  this.freeze();
820
930
  }
931
+ /** The id of the operation this call lowers to. */
932
+ get operationId() {
933
+ return `index.${this.tableName}.${this.indexName}`;
934
+ }
821
935
  async toOp(lowerer) {
822
936
  if (lowerer === void 0) throw sqliteError("MIGRATION.SQLITE_CONTROL_STACK_MISSING", `CreateIndexCall.toOp: a lowerer is required on the SQLite planner path (index "${this.indexName}" on table "${this.tableName}"). Pass the control adapter to createSqliteMigrationPlanner.`, { meta: {
823
937
  factory: this.factoryName,
@@ -828,7 +942,7 @@ var CreateIndexCall = class extends SqliteOpFactoryCallNode {
828
942
  const absent = await lowerer.lowerToExecuteRequest(checks.indexAbsent());
829
943
  const present = await lowerer.lowerToExecuteRequest(checks.indexPresent());
830
944
  return {
831
- id: `index.${this.tableName}.${this.indexName}`,
945
+ id: this.operationId,
832
946
  label: `Create index ${this.indexName} on ${this.tableName}`,
833
947
  summary: `Creates index ${this.indexName} on ${this.tableName}`,
834
948
  operationClass: "additive",
@@ -850,7 +964,7 @@ var CreateIndexCall = class extends SqliteOpFactoryCallNode {
850
964
  };
851
965
  var DropIndexCall = class extends SqliteOpFactoryCallNode {
852
966
  factoryName = "dropIndex";
853
- operationClass = "destructive";
967
+ operationClass = "widening";
854
968
  tableName;
855
969
  indexName;
856
970
  label;
@@ -861,6 +975,10 @@ var DropIndexCall = class extends SqliteOpFactoryCallNode {
861
975
  this.label = `Drop index ${indexName} on ${tableName}`;
862
976
  this.freeze();
863
977
  }
978
+ /** The id of the operation this call lowers to. */
979
+ get operationId() {
980
+ return `dropIndex.${this.tableName}.${this.indexName}`;
981
+ }
864
982
  async toOp(lowerer) {
865
983
  if (lowerer === void 0) throw sqliteError("MIGRATION.SQLITE_CONTROL_STACK_MISSING", `DropIndexCall.toOp: a lowerer is required on the SQLite planner path (index "${this.indexName}" on table "${this.tableName}"). Pass the control adapter to createSqliteMigrationPlanner.`, { meta: {
866
984
  factory: this.factoryName,
@@ -871,10 +989,10 @@ var DropIndexCall = class extends SqliteOpFactoryCallNode {
871
989
  const present = await lowerer.lowerToExecuteRequest(checks.indexPresent());
872
990
  const absent = await lowerer.lowerToExecuteRequest(checks.indexAbsent());
873
991
  return {
874
- id: `dropIndex.${this.tableName}.${this.indexName}`,
992
+ id: this.operationId,
875
993
  label: `Drop index ${this.indexName} on ${this.tableName}`,
876
994
  summary: `Drops index ${this.indexName} on ${this.tableName} which is not in the contract`,
877
- operationClass: "destructive",
995
+ operationClass: "widening",
878
996
  target: {
879
997
  id: "sqlite",
880
998
  details: buildTargetDetails("index", this.indexName, this.tableName)
@@ -899,7 +1017,7 @@ var DropIndexCall = class extends SqliteOpFactoryCallNode {
899
1017
  * any future strategy that needs a placeholder data step can construct one
900
1018
  * with its own id/label.
901
1019
  *
902
- * `toOp()` always throws `MIGRATION.UNFILLED_PLACEHOLDER`: the planner cannot lower a stubbed
1020
+ * `toOp()` always rejects with `MIGRATION.UNFILLED_PLACEHOLDER`: the planner cannot lower a stubbed
903
1021
  * transform to a runtime op — the user must edit the rendered
904
1022
  * `migration.ts` and re-emit.
905
1023
  */
@@ -919,7 +1037,7 @@ var DataTransformCall = class extends SqliteOpFactoryCallNode {
919
1037
  this.freeze();
920
1038
  }
921
1039
  toOp(_lowerer) {
922
- throw errorUnfilledPlaceholder(this.label);
1040
+ return unfilledPlaceholderOperation(this.label);
923
1041
  }
924
1042
  renderTypeScript() {
925
1043
  const slot = `${this.tableName}-${this.columnName}-backfill-sql`;
@@ -1013,6 +1131,6 @@ function renderPostcheck(postcheck) {
1013
1131
  }));
1014
1132
  }
1015
1133
  //#endregion
1016
- export { sqliteIdentifiersCollide as _, DropColumnCall as a, RawSqlCall as c, buildColumnTypeSql as d, buildRecreatePostchecks as f, sqliteDefaultToDdlColumnDefault as g, renderDefaultLiteral as h, DataTransformCall as i, RecreateTableCall as l, renameTableSteps as m, CreateIndexCall as n, DropIndexCall as o, buildRecreateSummary as p, CreateTableCall as r, DropTableCall as s, AddColumnCall as t, RenameTableCall as u, step as v };
1134
+ export { renameTableSteps as _, DropColumnCall as a, sqliteIdentifiersCollide as b, RawSqlCall as c, RenameTableCall as d, buildColumnTypeSql as f, isSqliteOpFactoryCall as g, indexReplacementCalls as h, DataTransformCall as i, RecreateTableCall as l, buildRecreateSummary as m, CreateIndexCall as n, DropIndexCall as o, buildRecreatePostchecks as p, CreateTableCall as r, DropTableCall as s, AddColumnCall as t, RenameColumnCall as u, renderDefaultLiteral as v, step as x, sqliteDefaultToDdlColumnDefault as y };
1017
1135
 
1018
- //# sourceMappingURL=op-factory-call-Bwp3QS4h-MwflmSX3.mjs.map
1136
+ //# sourceMappingURL=op-factory-call-Cwsf4slr-DRGuq5SV.mjs.map