MCPcopy Create free account
hub / github.com/mikro-orm/mikro-orm / serializePartition

Function serializePartition

packages/sql/src/schema/partitioning.ts:404–405  ·  view source on GitHub ↗
(partition: TablePartition)

Source from the content-addressed store, hash-verified

402
403 const normalizeSchema = (schema?: string) => (schema && schema !== defaultSchema ? schema : '');
404 const serializePartition = (partition: TablePartition) =>
405 `${normalizeSchema(partition.schema)}.${partition.name}:${normalizeQuotedIdentifiers(normalizePartitionBound(partition.bound))}`;
406
407 const fromPartitions = from.partitions.map(serializePartition).sort();
408 const toPartitions = to.partitions.map(serializePartition).sort();

Callers

nothing calls this directly

Calls 3

normalizeSchemaFunction · 0.85
normalizePartitionBoundFunction · 0.85

Tested by

no test coverage detected