@atscript/db 0.1.154 → 0.1.155
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/agg.d.cts +1 -1
- package/dist/agg.d.mts +1 -1
- package/dist/{buckets-jy8BfswO.d.cts → buckets-DcWm3SLt.d.cts} +120 -10
- package/dist/{buckets-CBKL_ZWE.d.mts → buckets-goCoky8v.d.mts} +120 -10
- package/dist/{column-diff-DAIAq6XR.mjs → column-diff-C68V_eYM.mjs} +346 -65
- package/dist/{column-diff-qnzx1o3c.cjs → column-diff-DMkGYAGM.cjs} +357 -64
- package/dist/{fk-diff-BIJ8l_hF.d.mts → fk-diff-BYLNWoF9.d.mts} +2 -1
- package/dist/{fk-diff-D1mrLMjU.d.cts → fk-diff-DblOPBLS.d.cts} +2 -1
- package/dist/index.cjs +2 -2
- package/dist/index.d.cts +10 -5
- package/dist/index.d.mts +10 -5
- package/dist/index.mjs +2 -2
- package/dist/plugin.cjs +3 -3
- package/dist/plugin.mjs +3 -3
- package/dist/rel.d.cts +2 -2
- package/dist/rel.d.mts +2 -2
- package/dist/{relation-helpers-BUsxNNGU.d.mts → relation-helpers-B9MVBrtx.d.mts} +1 -1
- package/dist/{relation-helpers-D_8bydc2.d.cts → relation-helpers-D9kMFfum.d.cts} +1 -1
- package/dist/shared.cjs +2 -1
- package/dist/shared.d.cts +10 -3
- package/dist/shared.d.mts +10 -3
- package/dist/shared.mjs +2 -2
- package/dist/sync.cjs +288 -30
- package/dist/sync.d.cts +34 -5
- package/dist/sync.d.mts +34 -5
- package/dist/sync.mjs +288 -30
- package/dist/{validation-utils-DqZAH6aT.mjs → validation-utils-DxHIqa36.mjs} +23 -5
- package/dist/{validation-utils-debIYpq0.cjs → validation-utils-_PA7iSLm.cjs} +28 -4
- package/dist/{validator-BACewoRj.mjs → validator-BC3nwFi4.mjs} +178 -10
- package/dist/{validator-BxWwh3wf.cjs → validator-DHwSyBej.cjs} +201 -9
- package/dist/validator.cjs +1 -1
- package/dist/validator.mjs +1 -1
- package/package.json +6 -6
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as TColumnDiff,
|
|
1
|
+
import { A as TColumnDiff, B as TDbDefaultFn, Tn as AtscriptDbReadable, U as TDbFieldMeta, V as TDbDefaultValue, W as TDbForeignKey, _t as TExistingColumn, at as TDbStorageType, ht as TDerivedColumn, in as AtscriptDbView, mn as AtscriptQueryNode, pn as AtscriptQueryFieldRef, yt as TExistingTableOption, z as TDbCollation } from "./buckets-goCoky8v.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/schema/schema-hash.d.ts
|
|
4
4
|
interface TFieldSnapshot {
|
|
@@ -225,6 +225,7 @@ declare function isColumnTypeChanged(existingType: string, expectedType: string)
|
|
|
225
225
|
*/
|
|
226
226
|
declare function computeColumnDiff(desired: readonly TDbFieldMeta[], existing: TExistingColumn[], typeMapper?: (field: TDbFieldMeta) => string, opts?: {
|
|
227
227
|
snapshot?: TTableSnapshot | null;
|
|
228
|
+
nativeDefaultFns?: ReadonlySet<TDbDefaultFn>;
|
|
228
229
|
}): TColumnDiff;
|
|
229
230
|
//#endregion
|
|
230
231
|
//#region src/schema/fk-diff.d.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as TColumnDiff,
|
|
1
|
+
import { A as TColumnDiff, B as TDbDefaultFn, Tn as AtscriptDbReadable, U as TDbFieldMeta, V as TDbDefaultValue, W as TDbForeignKey, _t as TExistingColumn, at as TDbStorageType, ht as TDerivedColumn, in as AtscriptDbView, mn as AtscriptQueryNode, pn as AtscriptQueryFieldRef, yt as TExistingTableOption, z as TDbCollation } from "./buckets-DcWm3SLt.cjs";
|
|
2
2
|
|
|
3
3
|
//#region src/schema/schema-hash.d.ts
|
|
4
4
|
interface TFieldSnapshot {
|
|
@@ -225,6 +225,7 @@ declare function isColumnTypeChanged(existingType: string, expectedType: string)
|
|
|
225
225
|
*/
|
|
226
226
|
declare function computeColumnDiff(desired: readonly TDbFieldMeta[], existing: TExistingColumn[], typeMapper?: (field: TDbFieldMeta) => string, opts?: {
|
|
227
227
|
snapshot?: TTableSnapshot | null;
|
|
228
|
+
nativeDefaultFns?: ReadonlySet<TDbDefaultFn>;
|
|
228
229
|
}): TColumnDiff;
|
|
229
230
|
//#endregion
|
|
230
231
|
//#region src/schema/fk-diff.d.ts
|
package/dist/index.cjs
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_db_error = require("./db-error-JcfJqqpk.cjs");
|
|
3
|
-
const require_column_diff = require("./column-diff-
|
|
3
|
+
const require_column_diff = require("./column-diff-DMkGYAGM.cjs");
|
|
4
4
|
const require_aggregate_fns = require("./aggregate-fns-DFtKAv7Q.cjs");
|
|
5
5
|
const require_nested_writer = require("./nested-writer-Bl1SZS7x.cjs");
|
|
6
|
+
const require_validator = require("./validator-DHwSyBej.cjs");
|
|
6
7
|
const require_search_fields = require("./search-fields-DwrsJUC1.cjs");
|
|
7
8
|
const require_object = require("./object-Djg28csK.cjs");
|
|
8
9
|
const require_consts = require("./consts-BzRfCcH2.cjs");
|
|
9
10
|
const require_ops = require("./ops.cjs");
|
|
10
|
-
const require_validator = require("./validator-BxWwh3wf.cjs");
|
|
11
11
|
let _atscript_typescript_utils = require("@atscript/typescript/utils");
|
|
12
12
|
let _uniqu_core = require("@uniqu/core");
|
|
13
13
|
let node_crypto = require("node:crypto");
|
package/dist/index.d.cts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { $ as TDbInsertResult, $t as
|
|
1
|
+
import { $ as TDbInsertResult, $t as BaseDbAdapter, A as TColumnDiff, An as ResolvedRelationFilter, At as TPrimaryKeyChange, B as TDbDefaultFn, Bn as relationStaticFilter, Bt as TViewJsonType, C as NavPropsOf, Cn as NativeIntegrity, Ct as TIdDescriptor, D as PrimaryKeyOf, Dn as resolveDesignType, Dt as TJsonCopyTarget, E as OwnPropsOf, En as DbResponse, Et as TInsertOptions, F as TDbActionLevel, Fn as andFilters, Ft as TSyncColumnResult, G as TDbIndex, Gn as TReadControls, Gt as UniqueryControls, H as TDbDeleteResult, Hn as TDbEncryptionOptions, Ht as TWriteTableResolver, I as TDbActionProcessor, In as containsRelationFilter, It as TTableOptionDiff, J as TDbInsertIgnoreOptions, Jn as TExprAggregate, Jt as isGeoIndexableType, K as TDbIndexField, Kn as NoopLogger, Kt as WithRelation, L as TDbActionTargetSummary, Ln as forEachResolvedRelation, Lt as TTableResolver, M as TCrudPermissions, Mn as TRelationFilterJunction, Mt as TRelationInfo, N as TDbActionInfo, Nn as TRelationFilterTable, Nt as TRowResolveOptions, O as TCascadeResolver, On as REL_FILTER_MAX_DEPTH, Ot as TMetaResponse, P as TDbActionIntent, Pn as TRelationStaticFilter, Pt as TSearchIndexInfo, Q as TDbInsertManyResult, Qt as ALL_VIEW_CAPABILITIES, R as TDbAvailableActions, Rn as hasRelationOp, Rt as TTouchManyOptions, S as FlatOf, Sn as IntegrityStrategy, St as TFkLookupTarget, T as NullsPlacement, Tn as AtscriptDbReadable, Tt as TIdentification, U as TDbFieldMeta, Un as DocumentFieldMapper, Ut as TypedWithRelation, V as TDbDefaultValue, Vn as DbEncryption, Vt as TWriteOptions, W as TDbForeignKey, Wn as FieldMappingStrategy, Wt as Uniquery, X as TDbInsertIgnoreSlot, Xn as TRowOrderKey, Xt as TPathPresence, Y as TDbInsertIgnoreResult, Yn as TFirstLast, Yt as isGeoPointType, Z as TDbInsertManyIgnoreResult, Zn as UniquSelect, Zt as ALL_BUCKET_UNITS, _ as DbPatch, _n as TViewPlan, _t as TExistingColumn, a as isJsonValueField, an as TViewColumnMapping, at as TDbStorageType, b as FieldOpsFor, bn as translateQueryTree, bt as TFieldMeta, c as resolveCalendarBuckets, cn as TViewReadPlan, ct as TDbWriteAction, d as AggregateFn, dn as AtscriptOrderItem, dt as TDbWriteGuard, en as TViewCapability, et as TDbObjectKind, f as AggregateQuery, fn as AtscriptQueryComparison, ft as TDbWriteGuardContext, g as DbControls, gn as TViewJoin, gt as TEnsureTableOptions, h as AtscriptDbWritable, hn as AtscriptRef, ht as TDerivedColumn, i as isBucketableField, in as AtscriptDbView, it as TDbRemoveGuardContext, j as TCrudOp, jn as TRelGuardState, jt as TReferencingForeignKey, k as TCascadeTarget, kn as REL_FILTER_MAX_NODES, kt as TMetadataOverrides, l as AggregateControls, ln as aliasTargetOf, lt as TDbWriteCheck, mn as AtscriptQueryNode, mt as TDerivedChangeReason, n as TComputedSelect, nn as TAdapterFactory, nt as TDbRelation, o as jsonValueAncestor, on as isAtscriptDbView, ot as TDbUpdateOptions, p as AggregateResult, pn as AtscriptQueryFieldRef, pt as TDeleteOptions, q as TDbIndexType, qn as TGenericLogger, qt as TableMetadata, r as TResolvedBucket, rn as TDbSpaceOptions, rt as TDbRemoveGuard, s as normalizeComputedSelect, sn as isViewType, st as TDbUpdateResult, t as TBucketFieldSource, tn as DbSpace, tt as TDbReferentialAction, u as AggregateExpr, un as AtscriptExprNode, ut as TDbWriteCheckContext, v as DbQuery, vn as evaluateExpr, vt as TExistingForeignKey, w as NullableOptional, wn as TCascadePin, wt as TIdResolveOptions, x as FilterExpr, xn as AtscriptDbTable, xt as TFkLookupResolver, y as DbRow, yn as isFieldRef, yt as TExistingTableOption, z as TDbCollation, zn as isResolvedRelationFilter, zt as TValueFormatterPair } from "./buckets-DcWm3SLt.cjs";
|
|
2
2
|
import { _ as separateFieldOps, a as $mul, c as $update, d as TDbFieldOp, f as TFieldOps, g as separateCas, h as reconcileCas, i as $insert, l as $upsert, m as isDbFieldOp, n as $dec, o as $remove, p as getDbFieldOp, r as $inc, s as $replace, t as $cas, u as TDbCas } from "./ops-AqhV7s9o.cjs";
|
|
3
3
|
import { a as isPlainObject, i as isEmptyObject, n as findAncestorInSet, o as selfOrAncestor, r as getPath, t as deletePath } from "./object-CtPYTIvy.cjs";
|
|
4
4
|
import { c as CalendarBucketLabel, d as WeekStart, g as ALL_AGGREGATE_FNS, l as ComputedExpr, o as BucketExpr, s as BucketUnit, u as ResolvedBucket } from "./agg-42CSpGDR.cjs";
|
|
5
5
|
import { _ as aggregateFailure, a as buildValidationContext, b as isRetryableDbError, c as isNavRelation, d as getKeyProps, f as CasExhaustedError, g as aggregateExpressionsNotSupported, h as DbErrorCode, l as TArrayPatch, m as DbError, n as ValidatorMode, p as CasMismatchError, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch, v as bucketTimeZoneUnavailable, y as isConflict } from "./validator-B3xlbrWf.cjs";
|
|
6
6
|
import { n as createDbValidatorPlugin, t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.cjs";
|
|
7
|
-
import { r as fkColumns, s as isColumnTypeChanged } from "./fk-diff-
|
|
8
|
-
import { i as tableNameOf } from "./relation-helpers-
|
|
7
|
+
import { r as fkColumns, s as isColumnTypeChanged } from "./fk-diff-DblOPBLS.cjs";
|
|
8
|
+
import { i as tableNameOf } from "./relation-helpers-D9kMFfum.cjs";
|
|
9
9
|
import { AggregateQuery as AggregateQuery$1, FilterExpr as FilterExpr$1, FilterVisitor, RELATION_OPS, RelationOp, RelationOp as RelationOp$1, ResolvedRowOrderKey, ResolvedSelectExpr, Uniquery as Uniquery$1, computeInsights, isPrimitive, isRelationOp, walkFilter } from "@uniqu/core";
|
|
10
10
|
import { AtscriptExprNode as AtscriptExprNode$1, TAtscriptAnnotatedType } from "@atscript/typescript/utils";
|
|
11
11
|
|
|
@@ -177,6 +177,11 @@ type TFilterPredicate = "compare" | "geo" | "exists" | "relation";
|
|
|
177
177
|
interface TFilterRef {
|
|
178
178
|
path: string;
|
|
179
179
|
predicate: TFilterPredicate;
|
|
180
|
+
/**
|
|
181
|
+
* The entry only tests presence (`null`, `$eq` / `$ne: null`, `$exists`)
|
|
182
|
+
* — the one filter a stored object accepts (since 0.1.155).
|
|
183
|
+
*/
|
|
184
|
+
nullTest?: boolean;
|
|
180
185
|
/**
|
|
181
186
|
* `relation` entries: each operator with its operand (a filter on the
|
|
182
187
|
* related table, not walked here). @since 0.1.147
|
|
@@ -386,7 +391,7 @@ declare function classifyQueryPath(source: TQueryPathSource, path: string): {
|
|
|
386
391
|
* `FieldCapabilityIndex`, with `$with` hints and leaf lists) is what clients
|
|
387
392
|
* see and is authoritative — the HTTP gate always answers first.
|
|
388
393
|
*/
|
|
389
|
-
declare function guardPath(meta: TableMetadata, adapter: BaseDbAdapter, path: string, op: TQueryPathOp, predicate?: TFilterPredicate): void;
|
|
394
|
+
declare function guardPath(meta: TableMetadata, adapter: BaseDbAdapter, path: string, op: TQueryPathOp, predicate?: TFilterPredicate, nullTest?: boolean): void;
|
|
390
395
|
/**
|
|
391
396
|
* Core backstop for every read / aggregate / mutation-filter entry point:
|
|
392
397
|
* each referenced path (see {@link collectQueryPaths}) must exist on THIS
|
|
@@ -686,4 +691,4 @@ declare function createFailureCollector(what: string): {
|
|
|
686
691
|
*/
|
|
687
692
|
declare function numericOperandProblem(fd: TDbFieldMeta): string | undefined;
|
|
688
693
|
//#endregion
|
|
689
|
-
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, ADAPTER_FILTER_REASON, ALL_AGGREGATE_FNS, ALL_BUCKET_UNITS, ALL_VIEW_CAPABILITIES, type AggregateControls, type AggregateExpr, type AggregateFn, type AggregateQuery, type AggregateResult, ApplicationIntegrity, AtscriptDbReadable, AtscriptDbTable, AtscriptDbView, type AtscriptDbWritable, type AtscriptExprNode, type AtscriptOrderItem, type AtscriptQueryComparison, type AtscriptQueryFieldRef, type AtscriptQueryNode, type AtscriptRef, BaseDbAdapter, type BucketExpr, type BucketUnit, type CalendarBucketLabel, CasExhaustedError, CasMismatchError, type ComputedExpr, DEFAULT_DB_SPACE, type DbControls, DbEncryption, DbError, type DbErrorCode, type DbPatch, type DbQuery, type DbResponse, type DbRow, DbSpace, type DbValidationContext, DocumentFieldMapper, ENCRYPTED_REASON, FieldMappingStrategy, type FieldOpsFor, type FilterExpr, type FilterVisitor, type FlatOf, INTEGER_REGEX_OP, IntegrityStrategy, NativeIntegrity, type NavPropsOf, NoopLogger, type NullableOptional, type NullsPlacement, type OwnPropsOf, type PrimaryKeyOf, RELATION_OPS, REL_FILTER_MAX_DEPTH, REL_FILTER_MAX_NODES, type RelationOp, RelationalFieldMapper, type ResolvedBucket, ResolvedRelationFilter, type TAdapterFactory, type TArrayPatch, type TBucketFieldSource, type TBucketSourceTable, type TBucketSourceVerdict, type TCascadeResolver, type TCascadeTarget, type TColumnDiff, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TDbActionTargetSummary, type TDbAvailableActions, type TDbCas, type TDbCollation, type TDbDefaultFn, type TDbDefaultValue, type TDbDeleteResult, type TDbEncryptionOptions, type TDbFieldMeta, type TDbFieldOp, type TDbForeignKey, type TDbIndex, type TDbIndexField, type TDbIndexType, type TDbInsertIgnoreOptions, type TDbInsertIgnoreResult, type TDbInsertIgnoreSlot, type TDbInsertManyIgnoreResult, type TDbInsertManyResult, type TDbInsertResult, type TDbObjectKind, type TDbPatch, type TDbReferentialAction, type TDbRelation, type TDbRemoveGuard, type TDbRemoveGuardContext, type TDbSpaceOptions, type TDbStorageType, type TDbUpdateOptions, type TDbUpdateResult, type TDbWriteAction, type TDbWriteCheck, type TDbWriteCheckContext, type TDbWriteGuard, type TDbWriteGuardContext, type TDeleteOptions, type TDerivedChangeReason, type TDerivedColumn, type TEnsureTableOptions, type TExistingColumn, type TExistingForeignKey, type TExistingTableOption, type TExprAggregate, type TFieldMeta, type TFieldOps, type TFilterPredicate, type TFilterRef, type TFirstLast, type TFkLookupResolver, type TFkLookupTarget, type TGenericLogger, type TGroupSourceVerdict, type TGuardedQuery, type TIdDescriptor, type TIdResolveOptions, type TIdentification, type TInsertOptions, type TMetaResponse, type TMetadataOverrides, type TPrimaryKeyChange, type TQueryPathKind, type TQueryPathOp, type TQueryPathRefs, type TQueryPathSource, type TReadColumnsKind, type TReadControls, type TReferencingForeignKey, type TRelationFilterJunction, type TRelationFilterTable, type TRelationInfo, type TRelationStaticFilter, type TResolvedBucket, type TRowOrderKey, type TRowResolveOptions, type TSearchIndexInfo, type TSearchMemberKind, type TSyncColumnResult, type TTableOptionDiff, type TTableResolver, type TTouchManyOptions, type TValueFormatterPair, type TViewCapability, type TViewColumnMapping, type TViewJoin, type TViewJsonType, type TViewPlan, type TViewReadPlan, type TWriteOptions, type TWriteTableResolver, TableMetadata, type TypedWithRelation, UniquSelect, type Uniquery, type UniqueryControls, type ValidationContext, type ValidatorMode, type WeekStart, type WithOptimisticRetryOptions, type WithRelation, acceptedOperatorsHint, aggregateExpressionsNotSupported, aggregateFailure, aliasTargetOf, andFilters, assertGeoPoint, assertNoVersionWrites, bucketSourceVerdict, bucketTimeZoneUnavailable, buildDbValidator, buildValidationContext, canFilterLeaf, checkHavingKeys, classifyQueryPath, collectQueryPaths, computeInsights, containsRelationFilter, createDbValidatorPlugin, createFailureCollector, decomposePatch, defaultFulltextIndex, deletePath, describeFulltext, evaluateExpr, findAncestorInSet, fkColumns, forEachResolvedRelation, forceNavNonOptional, geoIndexNotFoundMessage, getDbFieldOp, getKeyProps, getPath, groupSourceVerdict, guardAggregate, guardFilter, guardPath, guardPaths, guardQuery, hasRelationOp, isAtscriptDbView, isBucketableField, isColumnTypeChanged, isConflict, isDbEntityType, isDbFieldOp, isEmptyObject, isFieldRef, isGeoIndexableType, isGeoPointType, isJsonValueField, isNavRelation, isPlainObject, isPrimitive, isRelationOp, isResolvedRelationFilter, isRetryableDbError, isVersionExemptPatch, isViewType, jsonValueAncestor, narrowerFilterOps, normalizeComputedSelect, numericOperandProblem, queryReadColumns, reconcileCas, relationStaticFilter, resolveCalendarBuckets, resolveDesignType, searchIndexNotFoundMessage, searchMemberKind, searchTermInteger, selfOrAncestor, separateCas, separateFieldOps, sortFieldNames, splitFulltextFields, tableNameOf, translateQueryTree, uniqueKeyTuple, unsupportedOperatorMessage, vectorIndexNotFoundMessage, walkFilter, withOptimisticRetry };
|
|
694
|
+
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, ADAPTER_FILTER_REASON, ALL_AGGREGATE_FNS, ALL_BUCKET_UNITS, ALL_VIEW_CAPABILITIES, type AggregateControls, type AggregateExpr, type AggregateFn, type AggregateQuery, type AggregateResult, ApplicationIntegrity, AtscriptDbReadable, AtscriptDbTable, AtscriptDbView, type AtscriptDbWritable, type AtscriptExprNode, type AtscriptOrderItem, type AtscriptQueryComparison, type AtscriptQueryFieldRef, type AtscriptQueryNode, type AtscriptRef, BaseDbAdapter, type BucketExpr, type BucketUnit, type CalendarBucketLabel, CasExhaustedError, CasMismatchError, type ComputedExpr, DEFAULT_DB_SPACE, type DbControls, DbEncryption, DbError, type DbErrorCode, type DbPatch, type DbQuery, type DbResponse, type DbRow, DbSpace, type DbValidationContext, DocumentFieldMapper, ENCRYPTED_REASON, FieldMappingStrategy, type FieldOpsFor, type FilterExpr, type FilterVisitor, type FlatOf, INTEGER_REGEX_OP, IntegrityStrategy, NativeIntegrity, type NavPropsOf, NoopLogger, type NullableOptional, type NullsPlacement, type OwnPropsOf, type PrimaryKeyOf, RELATION_OPS, REL_FILTER_MAX_DEPTH, REL_FILTER_MAX_NODES, type RelationOp, RelationalFieldMapper, type ResolvedBucket, ResolvedRelationFilter, type TAdapterFactory, type TArrayPatch, type TBucketFieldSource, type TBucketSourceTable, type TBucketSourceVerdict, type TCascadeResolver, type TCascadeTarget, type TColumnDiff, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TDbActionTargetSummary, type TDbAvailableActions, type TDbCas, type TDbCollation, type TDbDefaultFn, type TDbDefaultValue, type TDbDeleteResult, type TDbEncryptionOptions, type TDbFieldMeta, type TDbFieldOp, type TDbForeignKey, type TDbIndex, type TDbIndexField, type TDbIndexType, type TDbInsertIgnoreOptions, type TDbInsertIgnoreResult, type TDbInsertIgnoreSlot, type TDbInsertManyIgnoreResult, type TDbInsertManyResult, type TDbInsertResult, type TDbObjectKind, type TDbPatch, type TDbReferentialAction, type TDbRelation, type TDbRemoveGuard, type TDbRemoveGuardContext, type TDbSpaceOptions, type TDbStorageType, type TDbUpdateOptions, type TDbUpdateResult, type TDbWriteAction, type TDbWriteCheck, type TDbWriteCheckContext, type TDbWriteGuard, type TDbWriteGuardContext, type TDeleteOptions, type TDerivedChangeReason, type TDerivedColumn, type TEnsureTableOptions, type TExistingColumn, type TExistingForeignKey, type TExistingTableOption, type TExprAggregate, type TFieldMeta, type TFieldOps, type TFilterPredicate, type TFilterRef, type TFirstLast, type TFkLookupResolver, type TFkLookupTarget, type TGenericLogger, type TGroupSourceVerdict, type TGuardedQuery, type TIdDescriptor, type TIdResolveOptions, type TIdentification, type TInsertOptions, type TJsonCopyTarget, type TMetaResponse, type TMetadataOverrides, type TPathPresence, type TPrimaryKeyChange, type TQueryPathKind, type TQueryPathOp, type TQueryPathRefs, type TQueryPathSource, type TReadColumnsKind, type TReadControls, type TReferencingForeignKey, type TRelationFilterJunction, type TRelationFilterTable, type TRelationInfo, type TRelationStaticFilter, type TResolvedBucket, type TRowOrderKey, type TRowResolveOptions, type TSearchIndexInfo, type TSearchMemberKind, type TSyncColumnResult, type TTableOptionDiff, type TTableResolver, type TTouchManyOptions, type TValueFormatterPair, type TViewCapability, type TViewColumnMapping, type TViewJoin, type TViewJsonType, type TViewPlan, type TViewReadPlan, type TWriteOptions, type TWriteTableResolver, TableMetadata, type TypedWithRelation, UniquSelect, type Uniquery, type UniqueryControls, type ValidationContext, type ValidatorMode, type WeekStart, type WithOptimisticRetryOptions, type WithRelation, acceptedOperatorsHint, aggregateExpressionsNotSupported, aggregateFailure, aliasTargetOf, andFilters, assertGeoPoint, assertNoVersionWrites, bucketSourceVerdict, bucketTimeZoneUnavailable, buildDbValidator, buildValidationContext, canFilterLeaf, checkHavingKeys, classifyQueryPath, collectQueryPaths, computeInsights, containsRelationFilter, createDbValidatorPlugin, createFailureCollector, decomposePatch, defaultFulltextIndex, deletePath, describeFulltext, evaluateExpr, findAncestorInSet, fkColumns, forEachResolvedRelation, forceNavNonOptional, geoIndexNotFoundMessage, getDbFieldOp, getKeyProps, getPath, groupSourceVerdict, guardAggregate, guardFilter, guardPath, guardPaths, guardQuery, hasRelationOp, isAtscriptDbView, isBucketableField, isColumnTypeChanged, isConflict, isDbEntityType, isDbFieldOp, isEmptyObject, isFieldRef, isGeoIndexableType, isGeoPointType, isJsonValueField, isNavRelation, isPlainObject, isPrimitive, isRelationOp, isResolvedRelationFilter, isRetryableDbError, isVersionExemptPatch, isViewType, jsonValueAncestor, narrowerFilterOps, normalizeComputedSelect, numericOperandProblem, queryReadColumns, reconcileCas, relationStaticFilter, resolveCalendarBuckets, resolveDesignType, searchIndexNotFoundMessage, searchMemberKind, searchTermInteger, selfOrAncestor, separateCas, separateFieldOps, sortFieldNames, splitFulltextFields, tableNameOf, translateQueryTree, uniqueKeyTuple, unsupportedOperatorMessage, vectorIndexNotFoundMessage, walkFilter, withOptimisticRetry };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { $ as TDbInsertResult, $t as
|
|
1
|
+
import { $ as TDbInsertResult, $t as BaseDbAdapter, A as TColumnDiff, An as ResolvedRelationFilter, At as TPrimaryKeyChange, B as TDbDefaultFn, Bn as relationStaticFilter, Bt as TViewJsonType, C as NavPropsOf, Cn as NativeIntegrity, Ct as TIdDescriptor, D as PrimaryKeyOf, Dn as resolveDesignType, Dt as TJsonCopyTarget, E as OwnPropsOf, En as DbResponse, Et as TInsertOptions, F as TDbActionLevel, Fn as andFilters, Ft as TSyncColumnResult, G as TDbIndex, Gn as TReadControls, Gt as UniqueryControls, H as TDbDeleteResult, Hn as TDbEncryptionOptions, Ht as TWriteTableResolver, I as TDbActionProcessor, In as containsRelationFilter, It as TTableOptionDiff, J as TDbInsertIgnoreOptions, Jn as TExprAggregate, Jt as isGeoIndexableType, K as TDbIndexField, Kn as NoopLogger, Kt as WithRelation, L as TDbActionTargetSummary, Ln as forEachResolvedRelation, Lt as TTableResolver, M as TCrudPermissions, Mn as TRelationFilterJunction, Mt as TRelationInfo, N as TDbActionInfo, Nn as TRelationFilterTable, Nt as TRowResolveOptions, O as TCascadeResolver, On as REL_FILTER_MAX_DEPTH, Ot as TMetaResponse, P as TDbActionIntent, Pn as TRelationStaticFilter, Pt as TSearchIndexInfo, Q as TDbInsertManyResult, Qt as ALL_VIEW_CAPABILITIES, R as TDbAvailableActions, Rn as hasRelationOp, Rt as TTouchManyOptions, S as FlatOf, Sn as IntegrityStrategy, St as TFkLookupTarget, T as NullsPlacement, Tn as AtscriptDbReadable, Tt as TIdentification, U as TDbFieldMeta, Un as DocumentFieldMapper, Ut as TypedWithRelation, V as TDbDefaultValue, Vn as DbEncryption, Vt as TWriteOptions, W as TDbForeignKey, Wn as FieldMappingStrategy, Wt as Uniquery, X as TDbInsertIgnoreSlot, Xn as TRowOrderKey, Xt as TPathPresence, Y as TDbInsertIgnoreResult, Yn as TFirstLast, Yt as isGeoPointType, Z as TDbInsertManyIgnoreResult, Zn as UniquSelect, Zt as ALL_BUCKET_UNITS, _ as DbPatch, _n as TViewPlan, _t as TExistingColumn, a as isJsonValueField, an as TViewColumnMapping, at as TDbStorageType, b as FieldOpsFor, bn as translateQueryTree, bt as TFieldMeta, c as resolveCalendarBuckets, cn as TViewReadPlan, ct as TDbWriteAction, d as AggregateFn, dn as AtscriptOrderItem, dt as TDbWriteGuard, en as TViewCapability, et as TDbObjectKind, f as AggregateQuery, fn as AtscriptQueryComparison, ft as TDbWriteGuardContext, g as DbControls, gn as TViewJoin, gt as TEnsureTableOptions, h as AtscriptDbWritable, hn as AtscriptRef, ht as TDerivedColumn, i as isBucketableField, in as AtscriptDbView, it as TDbRemoveGuardContext, j as TCrudOp, jn as TRelGuardState, jt as TReferencingForeignKey, k as TCascadeTarget, kn as REL_FILTER_MAX_NODES, kt as TMetadataOverrides, l as AggregateControls, ln as aliasTargetOf, lt as TDbWriteCheck, mn as AtscriptQueryNode, mt as TDerivedChangeReason, n as TComputedSelect, nn as TAdapterFactory, nt as TDbRelation, o as jsonValueAncestor, on as isAtscriptDbView, ot as TDbUpdateOptions, p as AggregateResult, pn as AtscriptQueryFieldRef, pt as TDeleteOptions, q as TDbIndexType, qn as TGenericLogger, qt as TableMetadata, r as TResolvedBucket, rn as TDbSpaceOptions, rt as TDbRemoveGuard, s as normalizeComputedSelect, sn as isViewType, st as TDbUpdateResult, t as TBucketFieldSource, tn as DbSpace, tt as TDbReferentialAction, u as AggregateExpr, un as AtscriptExprNode, ut as TDbWriteCheckContext, v as DbQuery, vn as evaluateExpr, vt as TExistingForeignKey, w as NullableOptional, wn as TCascadePin, wt as TIdResolveOptions, x as FilterExpr, xn as AtscriptDbTable, xt as TFkLookupResolver, y as DbRow, yn as isFieldRef, yt as TExistingTableOption, z as TDbCollation, zn as isResolvedRelationFilter, zt as TValueFormatterPair } from "./buckets-goCoky8v.mjs";
|
|
2
2
|
import { _ as separateFieldOps, a as $mul, c as $update, d as TDbFieldOp, f as TFieldOps, g as separateCas, h as reconcileCas, i as $insert, l as $upsert, m as isDbFieldOp, n as $dec, o as $remove, p as getDbFieldOp, r as $inc, s as $replace, t as $cas, u as TDbCas } from "./ops-AqhV7s9o.mjs";
|
|
3
3
|
import { a as isPlainObject, i as isEmptyObject, n as findAncestorInSet, o as selfOrAncestor, r as getPath, t as deletePath } from "./object-CtPYTIvy.mjs";
|
|
4
4
|
import { c as CalendarBucketLabel, d as WeekStart, g as ALL_AGGREGATE_FNS, l as ComputedExpr, o as BucketExpr, s as BucketUnit, u as ResolvedBucket } from "./agg-Wo-smrYV.mjs";
|
|
5
5
|
import { _ as aggregateFailure, a as buildValidationContext, b as isRetryableDbError, c as isNavRelation, d as getKeyProps, f as CasExhaustedError, g as aggregateExpressionsNotSupported, h as DbErrorCode, l as TArrayPatch, m as DbError, n as ValidatorMode, p as CasMismatchError, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch, v as bucketTimeZoneUnavailable, y as isConflict } from "./validator-B3xlbrWf.mjs";
|
|
6
6
|
import { n as createDbValidatorPlugin, t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.mjs";
|
|
7
|
-
import { r as fkColumns, s as isColumnTypeChanged } from "./fk-diff-
|
|
8
|
-
import { i as tableNameOf } from "./relation-helpers-
|
|
7
|
+
import { r as fkColumns, s as isColumnTypeChanged } from "./fk-diff-BYLNWoF9.mjs";
|
|
8
|
+
import { i as tableNameOf } from "./relation-helpers-B9MVBrtx.mjs";
|
|
9
9
|
import { AtscriptExprNode as AtscriptExprNode$1, TAtscriptAnnotatedType } from "@atscript/typescript/utils";
|
|
10
10
|
import { AggregateQuery as AggregateQuery$1, FilterExpr as FilterExpr$1, FilterVisitor, RELATION_OPS, RelationOp, RelationOp as RelationOp$1, ResolvedRowOrderKey, ResolvedSelectExpr, Uniquery as Uniquery$1, computeInsights, isPrimitive, isRelationOp, walkFilter } from "@uniqu/core";
|
|
11
11
|
|
|
@@ -177,6 +177,11 @@ type TFilterPredicate = "compare" | "geo" | "exists" | "relation";
|
|
|
177
177
|
interface TFilterRef {
|
|
178
178
|
path: string;
|
|
179
179
|
predicate: TFilterPredicate;
|
|
180
|
+
/**
|
|
181
|
+
* The entry only tests presence (`null`, `$eq` / `$ne: null`, `$exists`)
|
|
182
|
+
* — the one filter a stored object accepts (since 0.1.155).
|
|
183
|
+
*/
|
|
184
|
+
nullTest?: boolean;
|
|
180
185
|
/**
|
|
181
186
|
* `relation` entries: each operator with its operand (a filter on the
|
|
182
187
|
* related table, not walked here). @since 0.1.147
|
|
@@ -386,7 +391,7 @@ declare function classifyQueryPath(source: TQueryPathSource, path: string): {
|
|
|
386
391
|
* `FieldCapabilityIndex`, with `$with` hints and leaf lists) is what clients
|
|
387
392
|
* see and is authoritative — the HTTP gate always answers first.
|
|
388
393
|
*/
|
|
389
|
-
declare function guardPath(meta: TableMetadata, adapter: BaseDbAdapter, path: string, op: TQueryPathOp, predicate?: TFilterPredicate): void;
|
|
394
|
+
declare function guardPath(meta: TableMetadata, adapter: BaseDbAdapter, path: string, op: TQueryPathOp, predicate?: TFilterPredicate, nullTest?: boolean): void;
|
|
390
395
|
/**
|
|
391
396
|
* Core backstop for every read / aggregate / mutation-filter entry point:
|
|
392
397
|
* each referenced path (see {@link collectQueryPaths}) must exist on THIS
|
|
@@ -686,4 +691,4 @@ declare function createFailureCollector(what: string): {
|
|
|
686
691
|
*/
|
|
687
692
|
declare function numericOperandProblem(fd: TDbFieldMeta): string | undefined;
|
|
688
693
|
//#endregion
|
|
689
|
-
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, ADAPTER_FILTER_REASON, ALL_AGGREGATE_FNS, ALL_BUCKET_UNITS, ALL_VIEW_CAPABILITIES, type AggregateControls, type AggregateExpr, type AggregateFn, type AggregateQuery, type AggregateResult, ApplicationIntegrity, AtscriptDbReadable, AtscriptDbTable, AtscriptDbView, type AtscriptDbWritable, type AtscriptExprNode, type AtscriptOrderItem, type AtscriptQueryComparison, type AtscriptQueryFieldRef, type AtscriptQueryNode, type AtscriptRef, BaseDbAdapter, type BucketExpr, type BucketUnit, type CalendarBucketLabel, CasExhaustedError, CasMismatchError, type ComputedExpr, DEFAULT_DB_SPACE, type DbControls, DbEncryption, DbError, type DbErrorCode, type DbPatch, type DbQuery, type DbResponse, type DbRow, DbSpace, type DbValidationContext, DocumentFieldMapper, ENCRYPTED_REASON, FieldMappingStrategy, type FieldOpsFor, type FilterExpr, type FilterVisitor, type FlatOf, INTEGER_REGEX_OP, IntegrityStrategy, NativeIntegrity, type NavPropsOf, NoopLogger, type NullableOptional, type NullsPlacement, type OwnPropsOf, type PrimaryKeyOf, RELATION_OPS, REL_FILTER_MAX_DEPTH, REL_FILTER_MAX_NODES, type RelationOp, RelationalFieldMapper, type ResolvedBucket, ResolvedRelationFilter, type TAdapterFactory, type TArrayPatch, type TBucketFieldSource, type TBucketSourceTable, type TBucketSourceVerdict, type TCascadeResolver, type TCascadeTarget, type TColumnDiff, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TDbActionTargetSummary, type TDbAvailableActions, type TDbCas, type TDbCollation, type TDbDefaultFn, type TDbDefaultValue, type TDbDeleteResult, type TDbEncryptionOptions, type TDbFieldMeta, type TDbFieldOp, type TDbForeignKey, type TDbIndex, type TDbIndexField, type TDbIndexType, type TDbInsertIgnoreOptions, type TDbInsertIgnoreResult, type TDbInsertIgnoreSlot, type TDbInsertManyIgnoreResult, type TDbInsertManyResult, type TDbInsertResult, type TDbObjectKind, type TDbPatch, type TDbReferentialAction, type TDbRelation, type TDbRemoveGuard, type TDbRemoveGuardContext, type TDbSpaceOptions, type TDbStorageType, type TDbUpdateOptions, type TDbUpdateResult, type TDbWriteAction, type TDbWriteCheck, type TDbWriteCheckContext, type TDbWriteGuard, type TDbWriteGuardContext, type TDeleteOptions, type TDerivedChangeReason, type TDerivedColumn, type TEnsureTableOptions, type TExistingColumn, type TExistingForeignKey, type TExistingTableOption, type TExprAggregate, type TFieldMeta, type TFieldOps, type TFilterPredicate, type TFilterRef, type TFirstLast, type TFkLookupResolver, type TFkLookupTarget, type TGenericLogger, type TGroupSourceVerdict, type TGuardedQuery, type TIdDescriptor, type TIdResolveOptions, type TIdentification, type TInsertOptions, type TMetaResponse, type TMetadataOverrides, type TPrimaryKeyChange, type TQueryPathKind, type TQueryPathOp, type TQueryPathRefs, type TQueryPathSource, type TReadColumnsKind, type TReadControls, type TReferencingForeignKey, type TRelationFilterJunction, type TRelationFilterTable, type TRelationInfo, type TRelationStaticFilter, type TResolvedBucket, type TRowOrderKey, type TRowResolveOptions, type TSearchIndexInfo, type TSearchMemberKind, type TSyncColumnResult, type TTableOptionDiff, type TTableResolver, type TTouchManyOptions, type TValueFormatterPair, type TViewCapability, type TViewColumnMapping, type TViewJoin, type TViewJsonType, type TViewPlan, type TViewReadPlan, type TWriteOptions, type TWriteTableResolver, TableMetadata, type TypedWithRelation, UniquSelect, type Uniquery, type UniqueryControls, type ValidationContext, type ValidatorMode, type WeekStart, type WithOptimisticRetryOptions, type WithRelation, acceptedOperatorsHint, aggregateExpressionsNotSupported, aggregateFailure, aliasTargetOf, andFilters, assertGeoPoint, assertNoVersionWrites, bucketSourceVerdict, bucketTimeZoneUnavailable, buildDbValidator, buildValidationContext, canFilterLeaf, checkHavingKeys, classifyQueryPath, collectQueryPaths, computeInsights, containsRelationFilter, createDbValidatorPlugin, createFailureCollector, decomposePatch, defaultFulltextIndex, deletePath, describeFulltext, evaluateExpr, findAncestorInSet, fkColumns, forEachResolvedRelation, forceNavNonOptional, geoIndexNotFoundMessage, getDbFieldOp, getKeyProps, getPath, groupSourceVerdict, guardAggregate, guardFilter, guardPath, guardPaths, guardQuery, hasRelationOp, isAtscriptDbView, isBucketableField, isColumnTypeChanged, isConflict, isDbEntityType, isDbFieldOp, isEmptyObject, isFieldRef, isGeoIndexableType, isGeoPointType, isJsonValueField, isNavRelation, isPlainObject, isPrimitive, isRelationOp, isResolvedRelationFilter, isRetryableDbError, isVersionExemptPatch, isViewType, jsonValueAncestor, narrowerFilterOps, normalizeComputedSelect, numericOperandProblem, queryReadColumns, reconcileCas, relationStaticFilter, resolveCalendarBuckets, resolveDesignType, searchIndexNotFoundMessage, searchMemberKind, searchTermInteger, selfOrAncestor, separateCas, separateFieldOps, sortFieldNames, splitFulltextFields, tableNameOf, translateQueryTree, uniqueKeyTuple, unsupportedOperatorMessage, vectorIndexNotFoundMessage, walkFilter, withOptimisticRetry };
|
|
694
|
+
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, ADAPTER_FILTER_REASON, ALL_AGGREGATE_FNS, ALL_BUCKET_UNITS, ALL_VIEW_CAPABILITIES, type AggregateControls, type AggregateExpr, type AggregateFn, type AggregateQuery, type AggregateResult, ApplicationIntegrity, AtscriptDbReadable, AtscriptDbTable, AtscriptDbView, type AtscriptDbWritable, type AtscriptExprNode, type AtscriptOrderItem, type AtscriptQueryComparison, type AtscriptQueryFieldRef, type AtscriptQueryNode, type AtscriptRef, BaseDbAdapter, type BucketExpr, type BucketUnit, type CalendarBucketLabel, CasExhaustedError, CasMismatchError, type ComputedExpr, DEFAULT_DB_SPACE, type DbControls, DbEncryption, DbError, type DbErrorCode, type DbPatch, type DbQuery, type DbResponse, type DbRow, DbSpace, type DbValidationContext, DocumentFieldMapper, ENCRYPTED_REASON, FieldMappingStrategy, type FieldOpsFor, type FilterExpr, type FilterVisitor, type FlatOf, INTEGER_REGEX_OP, IntegrityStrategy, NativeIntegrity, type NavPropsOf, NoopLogger, type NullableOptional, type NullsPlacement, type OwnPropsOf, type PrimaryKeyOf, RELATION_OPS, REL_FILTER_MAX_DEPTH, REL_FILTER_MAX_NODES, type RelationOp, RelationalFieldMapper, type ResolvedBucket, ResolvedRelationFilter, type TAdapterFactory, type TArrayPatch, type TBucketFieldSource, type TBucketSourceTable, type TBucketSourceVerdict, type TCascadeResolver, type TCascadeTarget, type TColumnDiff, type TCrudOp, type TCrudPermissions, type TDbActionInfo, type TDbActionIntent, type TDbActionLevel, type TDbActionProcessor, type TDbActionTargetSummary, type TDbAvailableActions, type TDbCas, type TDbCollation, type TDbDefaultFn, type TDbDefaultValue, type TDbDeleteResult, type TDbEncryptionOptions, type TDbFieldMeta, type TDbFieldOp, type TDbForeignKey, type TDbIndex, type TDbIndexField, type TDbIndexType, type TDbInsertIgnoreOptions, type TDbInsertIgnoreResult, type TDbInsertIgnoreSlot, type TDbInsertManyIgnoreResult, type TDbInsertManyResult, type TDbInsertResult, type TDbObjectKind, type TDbPatch, type TDbReferentialAction, type TDbRelation, type TDbRemoveGuard, type TDbRemoveGuardContext, type TDbSpaceOptions, type TDbStorageType, type TDbUpdateOptions, type TDbUpdateResult, type TDbWriteAction, type TDbWriteCheck, type TDbWriteCheckContext, type TDbWriteGuard, type TDbWriteGuardContext, type TDeleteOptions, type TDerivedChangeReason, type TDerivedColumn, type TEnsureTableOptions, type TExistingColumn, type TExistingForeignKey, type TExistingTableOption, type TExprAggregate, type TFieldMeta, type TFieldOps, type TFilterPredicate, type TFilterRef, type TFirstLast, type TFkLookupResolver, type TFkLookupTarget, type TGenericLogger, type TGroupSourceVerdict, type TGuardedQuery, type TIdDescriptor, type TIdResolveOptions, type TIdentification, type TInsertOptions, type TJsonCopyTarget, type TMetaResponse, type TMetadataOverrides, type TPathPresence, type TPrimaryKeyChange, type TQueryPathKind, type TQueryPathOp, type TQueryPathRefs, type TQueryPathSource, type TReadColumnsKind, type TReadControls, type TReferencingForeignKey, type TRelationFilterJunction, type TRelationFilterTable, type TRelationInfo, type TRelationStaticFilter, type TResolvedBucket, type TRowOrderKey, type TRowResolveOptions, type TSearchIndexInfo, type TSearchMemberKind, type TSyncColumnResult, type TTableOptionDiff, type TTableResolver, type TTouchManyOptions, type TValueFormatterPair, type TViewCapability, type TViewColumnMapping, type TViewJoin, type TViewJsonType, type TViewPlan, type TViewReadPlan, type TWriteOptions, type TWriteTableResolver, TableMetadata, type TypedWithRelation, UniquSelect, type Uniquery, type UniqueryControls, type ValidationContext, type ValidatorMode, type WeekStart, type WithOptimisticRetryOptions, type WithRelation, acceptedOperatorsHint, aggregateExpressionsNotSupported, aggregateFailure, aliasTargetOf, andFilters, assertGeoPoint, assertNoVersionWrites, bucketSourceVerdict, bucketTimeZoneUnavailable, buildDbValidator, buildValidationContext, canFilterLeaf, checkHavingKeys, classifyQueryPath, collectQueryPaths, computeInsights, containsRelationFilter, createDbValidatorPlugin, createFailureCollector, decomposePatch, defaultFulltextIndex, deletePath, describeFulltext, evaluateExpr, findAncestorInSet, fkColumns, forEachResolvedRelation, forceNavNonOptional, geoIndexNotFoundMessage, getDbFieldOp, getKeyProps, getPath, groupSourceVerdict, guardAggregate, guardFilter, guardPath, guardPaths, guardQuery, hasRelationOp, isAtscriptDbView, isBucketableField, isColumnTypeChanged, isConflict, isDbEntityType, isDbFieldOp, isEmptyObject, isFieldRef, isGeoIndexableType, isGeoPointType, isJsonValueField, isNavRelation, isPlainObject, isPrimitive, isRelationOp, isResolvedRelationFilter, isRetryableDbError, isVersionExemptPatch, isViewType, jsonValueAncestor, narrowerFilterOps, normalizeComputedSelect, numericOperandProblem, queryReadColumns, reconcileCas, relationStaticFilter, resolveCalendarBuckets, resolveDesignType, searchIndexNotFoundMessage, searchMemberKind, searchTermInteger, selfOrAncestor, separateCas, separateFieldOps, sortFieldNames, splitFulltextFields, tableNameOf, translateQueryTree, uniqueKeyTuple, unsupportedOperatorMessage, vectorIndexNotFoundMessage, walkFilter, withOptimisticRetry };
|
package/dist/index.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { a as aggregateExpressionsNotSupported, c as isConflict, l as isRetryableDbError, n as CasMismatchError, o as aggregateFailure, r as DbError, s as bucketTimeZoneUnavailable, t as CasExhaustedError, u as spaceClosedError } from "./db-error-eSsQX7rt.mjs";
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as RelationalFieldMapper, A as AtscriptDbReadable, B as canFilterLeaf, C as ApplicationIntegrity, D as createFailureCollector, E as BaseDbAdapter, F as ADAPTER_FILTER_REASON, G as guardAggregate, H as classifyQueryPath, I as ENCRYPTED_REASON, J as guardPaths, K as guardFilter, L as acceptedOperatorsHint, M as geoIndexNotFoundMessage, N as searchIndexNotFoundMessage, O as IntegrityStrategy, P as vectorIndexNotFoundMessage, Q as unsupportedOperatorMessage, R as assertGeoPoint, S as decomposePatch, T as ALL_VIEW_CAPABILITIES, U as collectQueryPaths, V as checkHavingKeys, W as groupSourceVerdict, X as narrowerFilterOps, Y as guardQuery, Z as sortFieldNames, _ as isAtscriptDbView, _t as normalizeComputedSelect, at as defaultFulltextIndex, b as isVersionExemptPatch, ct as splitFulltextFields, dt as isGeoPointType, et as DocumentFieldMapper, g as AtscriptDbView, gt as jsonValueAncestor, ht as isJsonValueField, it as INTEGER_REGEX_OP, j as resolveDesignType, k as NativeIntegrity, lt as TableMetadata, mt as isBucketableField, n as isColumnTypeChanged, nt as UniquSelect, ot as describeFulltext, p as fkColumns, pt as aliasTargetOf, q as guardPath, rt as numericOperandProblem, st as searchTermInteger, tt as FieldMappingStrategy, ut as isGeoIndexableType, v as isViewType, vt as resolveCalendarBuckets, w as ALL_BUCKET_UNITS, x as assertNoVersionWrites, y as AtscriptDbTable, yt as NoopLogger, z as bucketSourceVerdict } from "./column-diff-C68V_eYM.mjs";
|
|
3
3
|
import { n as ALL_AGGREGATE_FNS } from "./aggregate-fns-B_sgl4mB.mjs";
|
|
4
4
|
import { A as hasRelationOp, C as REL_FILTER_MAX_DEPTH, D as containsRelationFilter, E as andFilters, G as evaluateExpr, H as tableNameOf, K as isFieldRef, P as relationStaticFilter, S as uniqueKeyTuple, T as ResolvedRelationFilter, j as isResolvedRelationFilter, k as forEachResolvedRelation, q as translateQueryTree, w as REL_FILTER_MAX_NODES } from "./nested-writer-BOj_c_lI.mjs";
|
|
5
|
+
import { a as forceNavNonOptional, c as getKeyProps, o as isNavRelation, r as buildValidationContext, s as createDbValidatorPlugin, t as buildDbValidator } from "./validator-BC3nwFi4.mjs";
|
|
5
6
|
import { i as DB_ENTITY_ANNOTATIONS, n as searchMemberKind } from "./search-fields-DBIZKwyb.mjs";
|
|
6
7
|
import { a as isPlainObject, i as isEmptyObject, n as findAncestorInSet, o as selfOrAncestor, r as getPath, t as deletePath } from "./object-TkiJQ-Dp.mjs";
|
|
7
8
|
import { t as DEFAULT_DB_SPACE } from "./consts-C_-5_pFq.mjs";
|
|
8
9
|
import { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, getDbFieldOp, isDbFieldOp, reconcileCas, separateCas, separateFieldOps } from "./ops.mjs";
|
|
9
|
-
import { a as forceNavNonOptional, c as getKeyProps, o as isNavRelation, r as buildValidationContext, s as createDbValidatorPlugin, t as buildDbValidator } from "./validator-BACewoRj.mjs";
|
|
10
10
|
import { isAnnotatedType } from "@atscript/typescript/utils";
|
|
11
11
|
import { RELATION_OPS, computeInsights, isPrimitive, isRelationOp, walkFilter } from "@uniqu/core";
|
|
12
12
|
import { createCipheriv, createDecipheriv, randomBytes } from "node:crypto";
|
package/dist/plugin.cjs
CHANGED
|
@@ -36,7 +36,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
36
36
|
const require_aggregate_fns = require("./aggregate-fns-DFtKAv7Q.cjs");
|
|
37
37
|
const require_search_fields = require("./search-fields-DwrsJUC1.cjs");
|
|
38
38
|
require("./consts-BzRfCcH2.cjs");
|
|
39
|
-
const require_validation_utils = require("./validation-utils-
|
|
39
|
+
const require_validation_utils = require("./validation-utils-_PA7iSLm.cjs");
|
|
40
40
|
let node_path = require("node:path");
|
|
41
41
|
node_path = __toESM(node_path, 1);
|
|
42
42
|
let node_url = require("node:url");
|
|
@@ -1701,7 +1701,7 @@ const dbSearchAnnotations = { search: {
|
|
|
1701
1701
|
* read sorts by it without a `$nulls` entry for it.
|
|
1702
1702
|
*/
|
|
1703
1703
|
const dbSortAnnotations = { sort: { nulls: new _atscript_core.AnnotationSpec({
|
|
1704
|
-
description: "Default **NULL placement** when a read sorts by this field and the request names none (`$nulls` control, URL suffix `$sort=-closedAt:last`).\n\n- **`'first'`** — rows where the field is NULL (or missing) come before every value, in both sort directions\n- **`'last'`** — they come after every value, in both directions\n\nWithout it (and without `$nulls`) NULL placement is the database's own: first in ascending order on SQLite, MySQL, MongoDB and the in-memory adapter, last on PostgreSQL. Applies to `$sort` and to the `$rowOrder` of `first()` / `last()`. Only optional fields can be NULL — on
|
|
1704
|
+
description: "Default **NULL placement** when a read sorts by this field and the request names none (`$nulls` control, URL suffix `$sort=-closedAt:last`).\n\n- **`'first'`** — rows where the field is NULL (or missing) come before every value, in both sort directions\n- **`'last'`** — they come after every value, in both directions\n\nWithout it (and without `$nulls`) NULL placement is the database's own: first in ascending order on SQLite, MySQL, MongoDB and the in-memory adapter, last on PostgreSQL. Applies to `$sort` and to the `$rowOrder` of `first()` / `last()`. Only optional and `| null` fields can be NULL — on another required table field it has no effect. On PostgreSQL, MySQL and MongoDB a placement the engine does not produce natively costs the index its ORDER BY (a sort step instead).\n\n**Example:**\n```atscript\n@db.sort.nulls 'last'\nclosedAt?: number.timestamp\n```\n",
|
|
1705
1705
|
nodeType: ["prop"],
|
|
1706
1706
|
passedWhenReferred: false,
|
|
1707
1707
|
multiple: false,
|
|
@@ -1736,7 +1736,7 @@ const dbSortAnnotations = { sort: { nulls: new _atscript_core.AnnotationSpec({
|
|
|
1736
1736
|
return errors;
|
|
1737
1737
|
}
|
|
1738
1738
|
const owner = require_validation_utils.getDbTableOwner(token);
|
|
1739
|
-
if (!field.has("optional") && owner && owner.countAnnotations("db.table") > 0 && field.ownerNode?.ownerNode === owner) fail("@db.sort.nulls on a required field has no effect — the field is never NULL; make it optional (field?: …) or remove the annotation", 2);
|
|
1739
|
+
if (!field.has("optional") && !require_validation_utils.isNullableUnion(def, doc) && owner && owner.countAnnotations("db.table") > 0 && field.ownerNode?.ownerNode === owner) fail("@db.sort.nulls on a required field has no effect — the field is never NULL; make it optional (field?: …) or remove the annotation", 2);
|
|
1740
1740
|
return errors;
|
|
1741
1741
|
}
|
|
1742
1742
|
}) } };
|
package/dist/plugin.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { i as NULL_WHEN_EMPTY_AGGREGATE_FNS, o as SUPPORTED_AGGREGATE_FNS, t as AGG_ANNOTATIONS } from "./aggregate-fns-B_sgl4mB.mjs";
|
|
2
2
|
import { a as DERIVED_INCOMPATIBLE, i as DB_ENTITY_ANNOTATIONS, o as JSON_LEAF_TYPES, r as numericTypeProblem } from "./search-fields-DBIZKwyb.mjs";
|
|
3
3
|
import "./consts-C_-5_pFq.mjs";
|
|
4
|
-
import { C as
|
|
4
|
+
import { C as validateExclusiveWith, S as searchFieldVerdict, T as validateSiblingStringField, _ as getParentTypeName, a as hasAnyViewAnnotation, b as primitiveBaseType, d as viewJoins, f as viewScopeTypes, g as getParentStruct, h as getNavTargetTypeName, i as forEachFieldRef, l as validateQueryScope, m as getDbTableOwner, n as findFKFieldsPointingTo, o as isAliasDecl, p as getAnnotationAlias, r as findViewCycle, s as isDbSourceDecl, t as earlierJoinTargets, u as validateRefArgument, v as integerMemberIndexProblem, w as validateFieldBaseType, x as refActionAnnotation, y as isNullableUnion } from "./validation-utils-DxHIqa36.mjs";
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
import { fileURLToPath } from "node:url";
|
|
7
7
|
import { AnnotationSpec, DEFAULT_FORMAT, getFieldsForType, isArray, isInterface, isPrimitive, isProp, isQueryComparison, isQueryLogical, isRef, isStructure } from "@atscript/core";
|
|
@@ -1665,7 +1665,7 @@ const dbSearchAnnotations = { search: {
|
|
|
1665
1665
|
* read sorts by it without a `$nulls` entry for it.
|
|
1666
1666
|
*/
|
|
1667
1667
|
const dbSortAnnotations = { sort: { nulls: new AnnotationSpec({
|
|
1668
|
-
description: "Default **NULL placement** when a read sorts by this field and the request names none (`$nulls` control, URL suffix `$sort=-closedAt:last`).\n\n- **`'first'`** — rows where the field is NULL (or missing) come before every value, in both sort directions\n- **`'last'`** — they come after every value, in both directions\n\nWithout it (and without `$nulls`) NULL placement is the database's own: first in ascending order on SQLite, MySQL, MongoDB and the in-memory adapter, last on PostgreSQL. Applies to `$sort` and to the `$rowOrder` of `first()` / `last()`. Only optional fields can be NULL — on
|
|
1668
|
+
description: "Default **NULL placement** when a read sorts by this field and the request names none (`$nulls` control, URL suffix `$sort=-closedAt:last`).\n\n- **`'first'`** — rows where the field is NULL (or missing) come before every value, in both sort directions\n- **`'last'`** — they come after every value, in both directions\n\nWithout it (and without `$nulls`) NULL placement is the database's own: first in ascending order on SQLite, MySQL, MongoDB and the in-memory adapter, last on PostgreSQL. Applies to `$sort` and to the `$rowOrder` of `first()` / `last()`. Only optional and `| null` fields can be NULL — on another required table field it has no effect. On PostgreSQL, MySQL and MongoDB a placement the engine does not produce natively costs the index its ORDER BY (a sort step instead).\n\n**Example:**\n```atscript\n@db.sort.nulls 'last'\nclosedAt?: number.timestamp\n```\n",
|
|
1669
1669
|
nodeType: ["prop"],
|
|
1670
1670
|
passedWhenReferred: false,
|
|
1671
1671
|
multiple: false,
|
|
@@ -1700,7 +1700,7 @@ const dbSortAnnotations = { sort: { nulls: new AnnotationSpec({
|
|
|
1700
1700
|
return errors;
|
|
1701
1701
|
}
|
|
1702
1702
|
const owner = getDbTableOwner(token);
|
|
1703
|
-
if (!field.has("optional") && owner && owner.countAnnotations("db.table") > 0 && field.ownerNode?.ownerNode === owner) fail("@db.sort.nulls on a required field has no effect — the field is never NULL; make it optional (field?: …) or remove the annotation", 2);
|
|
1703
|
+
if (!field.has("optional") && !isNullableUnion(def, doc) && owner && owner.countAnnotations("db.table") > 0 && field.ownerNode?.ownerNode === owner) fail("@db.sort.nulls on a required field has no effect — the field is never NULL; make it optional (field?: …) or remove the annotation", 2);
|
|
1704
1704
|
return errors;
|
|
1705
1705
|
}
|
|
1706
1706
|
}) } };
|
package/dist/rel.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { $t as BaseDbAdapter, Ht as TWriteTableResolver, Lt as TTableResolver, W as TDbForeignKey, h as AtscriptDbWritable, m as AtscriptDbTableLike, nt as TDbRelation, qn as TGenericLogger, qt as TableMetadata } from "./buckets-DcWm3SLt.cjs";
|
|
2
2
|
import { t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.cjs";
|
|
3
|
-
import { n as findRemoteFK, r as resolveRelationTargetTable, t as findFKForRelation } from "./relation-helpers-
|
|
3
|
+
import { n as findRemoteFK, r as resolveRelationTargetTable, t as findFKForRelation } from "./relation-helpers-D9kMFfum.cjs";
|
|
4
4
|
import { FilterExpr, WithRelation } from "@uniqu/core";
|
|
5
5
|
import { Validator } from "@atscript/typescript/utils";
|
|
6
6
|
|
package/dist/rel.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { $t as BaseDbAdapter, Ht as TWriteTableResolver, Lt as TTableResolver, W as TDbForeignKey, h as AtscriptDbWritable, m as AtscriptDbTableLike, nt as TDbRelation, qn as TGenericLogger, qt as TableMetadata } from "./buckets-goCoky8v.mjs";
|
|
2
2
|
import { t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.mjs";
|
|
3
|
-
import { n as findRemoteFK, r as resolveRelationTargetTable, t as findFKForRelation } from "./relation-helpers-
|
|
3
|
+
import { n as findRemoteFK, r as resolveRelationTargetTable, t as findFKForRelation } from "./relation-helpers-B9MVBrtx.mjs";
|
|
4
4
|
import { Validator } from "@atscript/typescript/utils";
|
|
5
5
|
import { FilterExpr, WithRelation } from "@uniqu/core";
|
|
6
6
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { W as TDbForeignKey, nt as TDbRelation } from "./buckets-
|
|
1
|
+
import { W as TDbForeignKey, nt as TDbRelation } from "./buckets-goCoky8v.mjs";
|
|
2
2
|
import { TAtscriptAnnotatedType } from "@atscript/typescript/utils";
|
|
3
3
|
|
|
4
4
|
//#region src/rel/relation-helpers.d.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { W as TDbForeignKey, nt as TDbRelation } from "./buckets-
|
|
1
|
+
import { W as TDbForeignKey, nt as TDbRelation } from "./buckets-DcWm3SLt.cjs";
|
|
2
2
|
import { TAtscriptAnnotatedType } from "@atscript/typescript/utils";
|
|
3
3
|
|
|
4
4
|
//#region src/rel/relation-helpers.d.ts
|
package/dist/shared.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_aggregate_rules = require("./aggregate-rules-D_bsCpUI.cjs");
|
|
3
|
-
const require_validation_utils = require("./validation-utils-
|
|
3
|
+
const require_validation_utils = require("./validation-utils-_PA7iSLm.cjs");
|
|
4
4
|
exports.NOT_DIMENSION_REASON = require_aggregate_rules.NOT_DIMENSION_REASON;
|
|
5
5
|
exports.earlierJoinTargets = require_validation_utils.earlierJoinTargets;
|
|
6
6
|
exports.findFKFieldsPointingTo = require_validation_utils.findFKFieldsPointingTo;
|
|
@@ -15,6 +15,7 @@ exports.hasAnyViewAnnotation = require_validation_utils.hasAnyViewAnnotation;
|
|
|
15
15
|
exports.integerMemberIndexProblem = require_validation_utils.integerMemberIndexProblem;
|
|
16
16
|
exports.isAliasDecl = require_validation_utils.isAliasDecl;
|
|
17
17
|
exports.isDbSourceDecl = require_validation_utils.isDbSourceDecl;
|
|
18
|
+
exports.isNullableUnion = require_validation_utils.isNullableUnion;
|
|
18
19
|
exports.isStrictAggregateStruct = require_aggregate_rules.isStrictAggregateStruct;
|
|
19
20
|
exports.joinTargets = require_validation_utils.joinTargets;
|
|
20
21
|
exports.primitiveBaseType = require_validation_utils.primitiveBaseType;
|
package/dist/shared.d.cts
CHANGED
|
@@ -8,6 +8,12 @@ declare function validateExclusiveWith(token: Token, selfName: string, others: A
|
|
|
8
8
|
}>): TMessages;
|
|
9
9
|
/** Primitive base type (`string`, `number`, `decimal`, …) of a resolved definition, if it is a primitive. */
|
|
10
10
|
declare function primitiveBaseType(def: SemanticNode | undefined): string | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Whether a definition is a union with a `null` member — `T | null`, or a
|
|
13
|
+
* ref to an alias of one (compile-time mirror of the runtime nullable union,
|
|
14
|
+
* since 0.1.155).
|
|
15
|
+
*/
|
|
16
|
+
declare function isNullableUnion(def: SemanticNode | undefined, doc: AtscriptDoc, depth?: number): boolean;
|
|
11
17
|
/**
|
|
12
18
|
* Whether a prop takes part in `$search` as text or as an integer, or why it
|
|
13
19
|
* cannot (compile-time mirror of the runtime `searchMemberKind`). Anything
|
|
@@ -22,8 +28,9 @@ declare function searchFieldVerdict(field: SemanticNode, doc: AtscriptDoc): {
|
|
|
22
28
|
/**
|
|
23
29
|
* Why an integer fulltext member is not index-backed (its exact-number match
|
|
24
30
|
* would scan — or fail on MongoDB next to `$text`), or `undefined`. Backed:
|
|
25
|
-
* `_id
|
|
26
|
-
*
|
|
31
|
+
* `_id` or the first `@meta.id` of an interface's own fields (an inline
|
|
32
|
+
* nested object's are no key of the row, like at runtime), or the first field
|
|
33
|
+
* (in declaration order) of a `@db.index.plain` / `@db.index.unique` group.
|
|
27
34
|
*/
|
|
28
35
|
declare function integerMemberIndexProblem(token: Token): string | undefined;
|
|
29
36
|
/** Asserts `args[0]` names a sibling property whose primitive base type is `string`. */
|
|
@@ -157,4 +164,4 @@ declare const NOT_DIMENSION_REASON = "not a dimension";
|
|
|
157
164
|
*/
|
|
158
165
|
declare function isStrictAggregateStruct(struct: SemanticStructureNode): boolean;
|
|
159
166
|
//#endregion
|
|
160
|
-
export { NOT_DIMENSION_REASON, TFKFieldMatch, TRefArgumentOptions, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|
|
167
|
+
export { NOT_DIMENSION_REASON, TFKFieldMatch, TRefArgumentOptions, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isNullableUnion, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|
package/dist/shared.d.mts
CHANGED
|
@@ -8,6 +8,12 @@ declare function validateExclusiveWith(token: Token, selfName: string, others: A
|
|
|
8
8
|
}>): TMessages;
|
|
9
9
|
/** Primitive base type (`string`, `number`, `decimal`, …) of a resolved definition, if it is a primitive. */
|
|
10
10
|
declare function primitiveBaseType(def: SemanticNode | undefined): string | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Whether a definition is a union with a `null` member — `T | null`, or a
|
|
13
|
+
* ref to an alias of one (compile-time mirror of the runtime nullable union,
|
|
14
|
+
* since 0.1.155).
|
|
15
|
+
*/
|
|
16
|
+
declare function isNullableUnion(def: SemanticNode | undefined, doc: AtscriptDoc, depth?: number): boolean;
|
|
11
17
|
/**
|
|
12
18
|
* Whether a prop takes part in `$search` as text or as an integer, or why it
|
|
13
19
|
* cannot (compile-time mirror of the runtime `searchMemberKind`). Anything
|
|
@@ -22,8 +28,9 @@ declare function searchFieldVerdict(field: SemanticNode, doc: AtscriptDoc): {
|
|
|
22
28
|
/**
|
|
23
29
|
* Why an integer fulltext member is not index-backed (its exact-number match
|
|
24
30
|
* would scan — or fail on MongoDB next to `$text`), or `undefined`. Backed:
|
|
25
|
-
* `_id
|
|
26
|
-
*
|
|
31
|
+
* `_id` or the first `@meta.id` of an interface's own fields (an inline
|
|
32
|
+
* nested object's are no key of the row, like at runtime), or the first field
|
|
33
|
+
* (in declaration order) of a `@db.index.plain` / `@db.index.unique` group.
|
|
27
34
|
*/
|
|
28
35
|
declare function integerMemberIndexProblem(token: Token): string | undefined;
|
|
29
36
|
/** Asserts `args[0]` names a sibling property whose primitive base type is `string`. */
|
|
@@ -157,4 +164,4 @@ declare const NOT_DIMENSION_REASON = "not a dimension";
|
|
|
157
164
|
*/
|
|
158
165
|
declare function isStrictAggregateStruct(struct: SemanticStructureNode): boolean;
|
|
159
166
|
//#endregion
|
|
160
|
-
export { NOT_DIMENSION_REASON, TFKFieldMatch, TRefArgumentOptions, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|
|
167
|
+
export { NOT_DIMENSION_REASON, TFKFieldMatch, TRefArgumentOptions, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isNullableUnion, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|
package/dist/shared.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { n as isStrictAggregateStruct, t as NOT_DIMENSION_REASON } from "./aggregate-rules-jdPrxqWa.mjs";
|
|
2
|
-
import { C as
|
|
3
|
-
export { NOT_DIMENSION_REASON, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|
|
2
|
+
import { C as validateExclusiveWith, S as searchFieldVerdict, T as validateSiblingStringField, _ as getParentTypeName, a as hasAnyViewAnnotation, b as primitiveBaseType, c as joinTargets, d as viewJoins, f as viewScopeTypes, g as getParentStruct, h as getNavTargetTypeName, i as forEachFieldRef, l as validateQueryScope, m as getDbTableOwner, n as findFKFieldsPointingTo, o as isAliasDecl, p as getAnnotationAlias, r as findViewCycle, s as isDbSourceDecl, t as earlierJoinTargets, u as validateRefArgument, v as integerMemberIndexProblem, w as validateFieldBaseType, x as refActionAnnotation, y as isNullableUnion } from "./validation-utils-DxHIqa36.mjs";
|
|
3
|
+
export { NOT_DIMENSION_REASON, earlierJoinTargets, findFKFieldsPointingTo, findViewCycle, forEachFieldRef, getAnnotationAlias, getDbTableOwner, getNavTargetTypeName, getParentStruct, getParentTypeName, hasAnyViewAnnotation, integerMemberIndexProblem, isAliasDecl, isDbSourceDecl, isNullableUnion, isStrictAggregateStruct, joinTargets, primitiveBaseType, refActionAnnotation, searchFieldVerdict, validateExclusiveWith, validateFieldBaseType, validateQueryScope, validateRefArgument, validateSiblingStringField, viewJoins, viewScopeTypes };
|