@prisma/orm-family-sql 8.0.0-rc.12-dev.15 → 8.0.0-rc.12-dev.17

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 (83) hide show
  1. package/dist/{authoring-type-constructors-C1ogrr_x-ChQC5e1v.mjs → authoring-type-constructors-C1ogrr_x-BZQc95SF.mjs} +2 -2
  2. package/dist/{authoring-type-constructors-C1ogrr_x-ChQC5e1v.mjs.map → authoring-type-constructors-C1ogrr_x-BZQc95SF.mjs.map} +1 -1
  3. package/dist/builder__runtime.d.mts +2 -2
  4. package/dist/builder__runtime.mjs +7 -7
  5. package/dist/builder__runtime.mjs.map +1 -1
  6. package/dist/{config-types-Dqe0LWuW.mjs → config-types-DlxXpXqA.mjs} +2 -2
  7. package/dist/{config-types-Dqe0LWuW.mjs.map → config-types-DlxXpXqA.mjs.map} +1 -1
  8. package/dist/{contract-builder-CojarVwS.mjs → contract-builder-3vURlaBN.mjs} +11 -12
  9. package/dist/contract-builder-3vURlaBN.mjs.map +1 -0
  10. package/dist/{contract-builder-C2VKBKK5.d.mts → contract-builder-Ct1IMc8_.d.mts} +311 -282
  11. package/dist/contract-builder-Ct1IMc8_.d.mts.map +1 -0
  12. package/dist/contract-emitter.mjs +1 -1
  13. package/dist/contract-prisma7__provider.mjs +2 -2
  14. package/dist/contract-psl.d.mts +2 -2
  15. package/dist/contract-psl.mjs +1 -1
  16. package/dist/contract-psl__provider.mjs +2 -2
  17. package/dist/contract-ts.d.mts +1 -1
  18. package/dist/contract-ts.mjs +3 -3
  19. package/dist/contract-ts__config-types.mjs +1 -1
  20. package/dist/contract-ts__contract-builder.d.mts +1 -1
  21. package/dist/contract-ts__contract-builder.mjs +2 -2
  22. package/dist/{control-DftpYMXw.d.mts → control-BKwzdenn.d.mts} +4 -4
  23. package/dist/{control-DftpYMXw.d.mts.map → control-BKwzdenn.d.mts.map} +1 -1
  24. package/dist/{control-BoloIwBt.mjs → control-BcWypsQy.mjs} +3 -3
  25. package/dist/{control-BoloIwBt.mjs.map → control-BcWypsQy.mjs.map} +1 -1
  26. package/dist/{derived-checks-BiClpWj6-Czjj2esH.mjs → derived-checks-Bsrdb2Wk-D4UfM06W.mjs} +93 -33
  27. package/dist/derived-checks-Bsrdb2Wk-D4UfM06W.mjs.map +1 -0
  28. package/dist/{diff-CHX4XHhC.d.mts → diff-B2b34L_E.d.mts} +4 -4
  29. package/dist/{diff-CHX4XHhC.d.mts.map → diff-B2b34L_E.d.mts.map} +1 -1
  30. package/dist/{dist-D5__KJs-.mjs → dist-U61NPKN3.mjs} +2 -2
  31. package/dist/{dist-D5__KJs-.mjs.map → dist-U61NPKN3.mjs.map} +1 -1
  32. package/dist/family.d.mts +6 -6
  33. package/dist/family.mjs +2 -2
  34. package/dist/family__control.d.mts +3 -3
  35. package/dist/family__control.mjs +1 -1
  36. package/dist/family__diff.d.mts +1 -1
  37. package/dist/family__migration.d.mts +1 -1
  38. package/dist/family__pack.mjs +1 -1
  39. package/dist/family__runtime.d.mts +1 -1
  40. package/dist/family__runtime.mjs +1 -1
  41. package/dist/{index-C10GDLBQ.d.mts → index-B-CraAhf.d.mts} +4 -4
  42. package/dist/{index-C10GDLBQ.d.mts.map → index-B-CraAhf.d.mts.map} +1 -1
  43. package/dist/{interpreter-BrW0_y8Q-Dl5e-p7f.mjs → interpreter-BrW0_y8Q-ChkFlzaN.mjs} +2 -2
  44. package/dist/{interpreter-BrW0_y8Q-Dl5e-p7f.mjs.map → interpreter-BrW0_y8Q-ChkFlzaN.mjs.map} +1 -1
  45. package/dist/{migration-BwA1d1OP.d.mts → migration-9GrLWqGg.d.mts} +2 -2
  46. package/dist/{migration-BwA1d1OP.d.mts.map → migration-9GrLWqGg.d.mts.map} +1 -1
  47. package/dist/orm-client.d.mts +6 -6
  48. package/dist/orm-client.mjs +10 -10
  49. package/dist/orm-client.mjs.map +1 -1
  50. package/dist/{prepared-statement-B6zvhJej-Dl488oBR.d.mts → prepared-statement-BHSj2pDk-CRzjNpcv.d.mts} +9 -26
  51. package/dist/prepared-statement-BHSj2pDk-CRzjNpcv.d.mts.map +1 -0
  52. package/dist/query-lane-context-BcXiJasG.d.mts +1 -0
  53. package/dist/{query-lane-context-Bi1GUXHp-Bo4OTjhW.d.mts → query-lane-context-D6o9YrEV-bouFPM6u.d.mts} +5 -31
  54. package/dist/query-lane-context-D6o9YrEV-bouFPM6u.d.mts.map +1 -0
  55. package/dist/relational-core.d.mts +4 -4
  56. package/dist/relational-core__aggregate-descriptor-registry.d.mts +1 -1
  57. package/dist/relational-core__codec-descriptor-registry.d.mts +1 -1
  58. package/dist/relational-core__query-lane-context.d.mts +3 -3
  59. package/dist/relational-core__types.d.mts +2 -2
  60. package/dist/{runtime-DYpzLADy.d.mts → runtime-DgOeosYa.d.mts} +5 -6
  61. package/dist/runtime-DgOeosYa.d.mts.map +1 -0
  62. package/dist/{runtime-DzmRvRj_.mjs → runtime-Z3nD7ix1.mjs} +4 -4
  63. package/dist/{runtime-DzmRvRj_.mjs.map → runtime-Z3nD7ix1.mjs.map} +1 -1
  64. package/dist/runtime.d.mts +4 -4
  65. package/dist/runtime.mjs +7 -85
  66. package/dist/runtime.mjs.map +1 -1
  67. package/dist/runtime__internal__prepared-query.d.mts +1 -1
  68. package/dist/{schema-differ-DpG_gnur-CXVM1Oed.d.mts → schema-differ-DpG_gnur-B_rj2WAH.d.mts} +2 -2
  69. package/dist/{schema-differ-DpG_gnur-CXVM1Oed.d.mts.map → schema-differ-DpG_gnur-B_rj2WAH.d.mts.map} +1 -1
  70. package/dist/{types-BFPRCYGW-BheztqYQ.d.mts → types-BFPRCYGW-DWAEoFj7.d.mts} +2 -2
  71. package/dist/{types-BFPRCYGW-BheztqYQ.d.mts.map → types-BFPRCYGW-DWAEoFj7.d.mts.map} +1 -1
  72. package/dist/types-BvTYXSiS.d.mts +1 -0
  73. package/dist/{types-Bcujdkdw-2SDajXRo.d.mts → types-DFJNPLXY-vp6AGe5e.d.mts} +3 -3
  74. package/dist/{types-Bcujdkdw-2SDajXRo.d.mts.map → types-DFJNPLXY-vp6AGe5e.d.mts.map} +1 -1
  75. package/package.json +18 -18
  76. package/dist/contract-builder-C2VKBKK5.d.mts.map +0 -1
  77. package/dist/contract-builder-CojarVwS.mjs.map +0 -1
  78. package/dist/derived-checks-BiClpWj6-Czjj2esH.mjs.map +0 -1
  79. package/dist/prepared-statement-B6zvhJej-Dl488oBR.d.mts.map +0 -1
  80. package/dist/query-lane-context-Bi1GUXHp-Bo4OTjhW.d.mts.map +0 -1
  81. package/dist/query-lane-context-CJNBt8cm.d.mts +0 -1
  82. package/dist/runtime-DYpzLADy.d.mts.map +0 -1
  83. package/dist/types-nNy0nND_.d.mts +0 -1
@@ -1,6 +1,6 @@
1
1
  import { c as SqlStorage } from "./sql-storage-8LqxeLAY-DH4DdUXx.mjs";
2
2
  import "./types-C36_3E6_.mjs";
3
- import { f as SqlMigrationPlanOperation, w as SqlPlanTargetDetails } from "./types-BFPRCYGW-BheztqYQ.mjs";
3
+ import { f as SqlMigrationPlanOperation, w as SqlPlanTargetDetails } from "./types-BFPRCYGW-DWAEoFj7.mjs";
4
4
  import { Contract } from "@prisma/orm-framework/contract/types";
5
5
  import { Migration } from "@prisma/orm-toolchain/migration-tools/migration";
6
6
  //#region ../../../2-sql/9-family/dist/migration.d.mts
@@ -41,4 +41,4 @@ declare abstract class SqlMigration<TDetails extends SqlPlanTargetDetails, TTarg
41
41
  }
42
42
  //#endregion
43
43
  export { SqlMigration as t };
44
- //# sourceMappingURL=migration-BwA1d1OP.d.mts.map
44
+ //# sourceMappingURL=migration-9GrLWqGg.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"migration-BwA1d1OP.d.mts","names":[],"sources":["../../../../2-sql/9-family/dist/migration.d.mts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;uBA0BuB,aAAa,iBAAiB,sBAAsB,mCAAmC,cAAc,SAAS,cAAc,SAAS,aAAa,YAAY,SAAS,cAAc,SAAS,qBAAqB,UAAU,0BAA0B,kBAAkB,WAAW,OAAO;;;;;;;;;;;MAW5S"}
1
+ {"version":3,"file":"migration-9GrLWqGg.d.mts","names":[],"sources":["../../../../2-sql/9-family/dist/migration.d.mts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;uBA0BuB,aAAa,iBAAiB,sBAAsB,mCAAmC,cAAc,SAAS,cAAc,SAAS,aAAa,YAAY,SAAS,cAAc,SAAS,qBAAqB,UAAU,0BAA0B,kBAAkB,WAAW,OAAO;;;;;;;;;;;MAW5S"}
@@ -7,12 +7,12 @@ import "./ast-B9jF6tRJ.mjs";
7
7
  import { n as SqlQueryPlan, t as Preparable } from "./plan-B7g2kDfQ-Bw0784x6.mjs";
8
8
  import { S as TraitExpression, i as CodecTypesBase, o as Expression } from "./expression-BPoA5eEl.mjs";
9
9
  import "./plan-DiT00Rg8.mjs";
10
- import { r as ExecutionContext } from "./query-lane-context-Bi1GUXHp-Bo4OTjhW.mjs";
11
- import "./query-lane-context-CJNBt8cm.mjs";
12
- import { h as RuntimeScope, o as ComputeColumnJsType } from "./types-Bcujdkdw-2SDajXRo.mjs";
13
- import "./types-nNy0nND_.mjs";
14
- import { T as RuntimeQueryable$1, l as ParamsFromDeclaration, m as PreparedStatement, p as PreparedFor, r as Declaration, t as BindSiteParams, y as Runtime } from "./prepared-statement-B6zvhJej-Dl488oBR.mjs";
15
- import "./index-C10GDLBQ.mjs";
10
+ import { n as ExecutionContext } from "./query-lane-context-D6o9YrEV-bouFPM6u.mjs";
11
+ import "./query-lane-context-BcXiJasG.mjs";
12
+ import { h as RuntimeScope, o as ComputeColumnJsType } from "./types-DFJNPLXY-vp6AGe5e.mjs";
13
+ import "./types-BvTYXSiS.mjs";
14
+ import { C as RuntimeQueryable$1, c as ParamsFromDeclaration, f as PreparedFor, p as PreparedStatement, r as Declaration, t as BindSiteParams, v as Runtime } from "./prepared-statement-BHSj2pDk-CRzjNpcv.mjs";
15
+ import "./index-B-CraAhf.mjs";
16
16
  import { Contract } from "@prisma/orm-framework/contract/types";
17
17
  import { AnnotationValue, AsyncIterableResult, MetaBuilder, OperationKind, ResultType, RuntimeExecuteOptions } from "@prisma/orm-framework/components/runtime";
18
18
  import { SimplifyDeep } from "@prisma/orm-framework/utils/simplify-deep";
@@ -3444,11 +3444,11 @@ async function updateFirstGraph(scope, context, namespaceId, modelName, filters,
3444
3444
  const tableName = resolveModelTableName(contract, namespaceId, modelName);
3445
3445
  const appliedUpdateDefaults = context.applyMutationDefaults({
3446
3446
  op: "update",
3447
- table: tableName,
3447
+ entry: tableName,
3448
3448
  namespace: namespaceId,
3449
3449
  values: mappedUpdateData
3450
3450
  });
3451
- for (const def of appliedUpdateDefaults) mappedUpdateData[def.column] = def.value;
3451
+ for (const def of appliedUpdateDefaults) mappedUpdateData[def.field] = def.value;
3452
3452
  const identityWhere = shorthandToWhereExpr(context, namespaceId, modelName, castAs(buildRowIdentityFilterFromRow(contract, namespaceId, modelName, existingRow)));
3453
3453
  if (!identityWhere) throw new InternalError(`Failed to build row identity filter for model "${modelName}"`);
3454
3454
  const updatedRaw = (await queryPlanRows(scope, compileUpdateReturning(contract, namespaceId, tableName, mappedUpdateData, [identityWhere], void 0)).toArray())[0];
@@ -3712,11 +3712,11 @@ async function insertJunctionLink(scope, context, relation, parentPkValues, targ
3712
3712
  for (const [column, value] of targetPkValues.entries()) writeJunctionColumn(junctionRow, through, column, value, relation.relationName);
3713
3713
  const applied = context.applyMutationDefaults({
3714
3714
  op: "create",
3715
- table: through.table,
3715
+ entry: through.table,
3716
3716
  namespace: through.namespaceId,
3717
3717
  values: junctionRow
3718
3718
  });
3719
- for (const def of applied) junctionRow[def.column] = def.value;
3719
+ for (const def of applied) junctionRow[def.field] = def.value;
3720
3720
  const compiled = compileInsertCount(context.contract, through.namespaceId, through.table, [junctionRow]);
3721
3721
  try {
3722
3722
  await scope.execute(compiled);
@@ -3769,11 +3769,11 @@ async function insertSingleRow(scope, context, namespaceId, modelName, data) {
3769
3769
  const mappedData = mapModelDataToStorageRow(contract, namespaceId, modelName, data);
3770
3770
  const applied = context.applyMutationDefaults({
3771
3771
  op: "create",
3772
- table: tableName,
3772
+ entry: tableName,
3773
3773
  namespace: namespaceId,
3774
3774
  values: mappedData
3775
3775
  });
3776
- for (const def of applied) mappedData[def.column] = def.value;
3776
+ for (const def of applied) mappedData[def.field] = def.value;
3777
3777
  const firstRow = (await queryPlanRows(scope, compileInsertReturning(contract, namespaceId, tableName, [mappedData], void 0)).toArray())[0];
3778
3778
  if (!firstRow) throw ormError("ORM.MUTATION_ROW_MISSING", `Nested create for model "${modelName}" did not return a row`, { meta: {
3779
3779
  operation: "create",
@@ -3859,22 +3859,22 @@ function applyCreateDefaults(ctx, namespaceId, tableName, rows, defaultValueCach
3859
3859
  for (const row of rows) {
3860
3860
  const applied = ctx.context.applyMutationDefaults({
3861
3861
  op: "create",
3862
- table: tableName,
3862
+ entry: tableName,
3863
3863
  namespace: namespaceId,
3864
3864
  values: row,
3865
3865
  defaultValueCache
3866
3866
  });
3867
- for (const def of applied) row[def.column] = def.value;
3867
+ for (const def of applied) row[def.field] = def.value;
3868
3868
  }
3869
3869
  }
3870
3870
  function applyUpdateDefaults(ctx, namespaceId, tableName, values) {
3871
3871
  const applied = ctx.context.applyMutationDefaults({
3872
3872
  op: "update",
3873
- table: tableName,
3873
+ entry: tableName,
3874
3874
  namespace: namespaceId,
3875
3875
  values
3876
3876
  });
3877
- for (const def of applied) values[def.column] = def.value;
3877
+ for (const def of applied) values[def.field] = def.value;
3878
3878
  }
3879
3879
  function isToWhereExprInput(value) {
3880
3880
  return typeof value === "object" && value !== null && "toWhereExpr" in value && typeof value.toWhereExpr === "function";