MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / runGroups

Function runGroups

packages/core/fumadb/src/query/orm/index.ts:507–520  ·  view source on GitHub ↗
(adapter: ORMAdapter<S>)

Source from the content-addressed store, hash-verified

505 }
506 }
507 const runGroups = async (adapter: ORMAdapter<S>): Promise<void> => {
508 if (!adapter.upsertMany) {
509 // oxlint-disable-next-line executor/no-try-catch-or-throw, executor/no-error-constructor -- boundary: a transaction adapter must mirror the base adapter's upsertMany support
510 throw new Error("[FumaDB] Transaction adapter does not support upsertMany.");
511 }
512 for (const group of groups) {
513 await adapter.upsertMany(table, {
514 target: targetColumns,
515 update: updateColumns,
516 values: group.values,
517 where: group.where,
518 });
519 }
520 };
521
522 // A single group is one adapter call, which is as atomic as the
523 // engine allows. Multiple predicate groups are separate adapter

Callers 1

upsertManyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected