Skip to content

Preserve null for empty relation SUM instead of implicit zero #271

Open

Description

@philipgreat

Core program: teaql/teaql-conformance#236. The maintainer confirmed COUNT(empty)=0 and SUM(empty or all-null)=null; an explicit caller fallback may return zero. PortableSQLDataService.attachDynamicAggregations currently initializes every single-number aggregate to 0 regardless of its operator. This invents a SUM result for absent relation buckets. Scope: operator-aware missing-bucket materialization, nullable values retained through dynamic properties, real SQLite regressions and a generated Q/E example. Preserve COUNT behavior, real zero and per-statement TraceChain; do not change physical schema or hand-edit generated implementations. Verify the old implementation fails the same regression before qualifying the candidate. Local source and internal artifacts only; no public release authorized.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions