Filing gate: ① a product defect with a measured reach:. Finding class (a). reach: POST /api/v1/data/:object/query, measured by the #20783 dev on origin/main 7a09eee1b1 and at PR #20804's head 43ae6c1fc, on InMemoryDriver, SqlDriver SQLite and a live PostgreSQL 16.13 (os-dev-report on #20783, out_of_scope_findings[1] and [2]). The readings are the dev's; the seat did not re-run them.
Filed by the domain:engine execution seat 1 (session_01DEvba2nBuD4tWzfq8r8NFY, os-support-ai). ⛔ Filed bare: routing and grading belong to triage. ⛔ Not a claim. Reader: triage, then the seat that owns packages/objectql and the drivers; the count_distinct half has a packages/spec seam.
What happens
Both are the same family as #20783 (a JSON-stored column used as a group or distinct key answering per driver, with a PostgreSQL 500), but neither is #20783's class, so PR #20804 left them:
| query |
memory |
SQLite |
PostgreSQL 16 |
{ groupBy: ['tags'], aggregations: [count] }, tags a multiple: true select |
200, one group per array |
200, one group per serialized array |
500 DATABASE_ERROR ("could not identify an equality operator for type json") |
{ aggregations: [{ function: 'count_distinct', field: 'meta', alias: 'n' }] }, meta a json field |
3 |
3 |
500 DATABASE_ERROR |
Scope for whoever takes it (⛔ not a ruling)
- One answer per query on every driver, never a 500. For the multi-value
groupBy: either the stated meaning (one bucket per member) on every driver, or a refusal. For count_distinct on a structured-JSON field: the compatibility table stops accepting it (a packages/spec change), or every backend is given one reading.
- Pins on memory, SQLite and PostgreSQL, with a scalar control for each.
Dedupe
mcp__github__search_issues, repo-scoped, open and closed, in the act that filed this card:
Dedupe words: groupBy multiple select postgres 500 · group by multi-value field json column · count_distinct json field postgres 500 · aggregate field type compatibility count_distinct json
Generated by Claude Code
Filing gate: ① a product defect with a measured
reach:. Finding class (a).reach:POST /api/v1/data/:object/query, measured by the #20783 dev onorigin/main7a09eee1b1and at PR #20804's head43ae6c1fc, on InMemoryDriver, SqlDriver SQLite and a live PostgreSQL 16.13 (os-dev-reporton #20783,out_of_scope_findings[1]and[2]). The readings are the dev's; the seat did not re-run them.Filed by the
domain:engineexecution seat 1 (session_01DEvba2nBuD4tWzfq8r8NFY,os-support-ai). ⛔ Filed bare: routing and grading belong to triage. ⛔ Not a claim. Reader: triage, then the seat that ownspackages/objectqland the drivers; thecount_distincthalf has apackages/specseam.What happens
Both are the same family as #20783 (a JSON-stored column used as a group or distinct key answering per driver, with a PostgreSQL 500), but neither is #20783's class, so PR #20804 left them:
{ groupBy: ['tags'], aggregations: [count] },tagsamultiple: trueselectDATABASE_ERROR("could not identify an equality operator for type json"){ aggregations: [{ function: 'count_distinct', field: 'meta', alias: 'n' }] },metaajsonfieldDATABASE_ERRORgroupBy: unlike ajsondocument, a multi-value field has a plausible other meaning (a bucket per member), which is why [finding]groupByon ajsonfield answers 500DATABASE_ERRORon PostgreSQL, one merged group on memory, and one group per serialized value on SQLite #20783 did not refuse it.count_distinct: spec'sAGGREGATE_FIELD_TYPE_COMPATIBILITYacceptscount_distinctfor everyFieldType, on the stated ground that the table answers "can every backend give one answer". On PostgreSQL,COUNT(DISTINCT json)cannot. Seam:spec:AGGREGATE_FIELD_TYPE_COMPATIBILITY.count_distinct→runtime:driver-sql aggregate.Scope for whoever takes it (⛔ not a ruling)
groupBy: either the stated meaning (one bucket per member) on every driver, or a refusal. Forcount_distincton a structured-JSON field: the compatibility table stops accepting it (apackages/specchange), or every backend is given one reading.Dedupe
mcp__github__search_issues, repo-scoped, open and closed, in the act that filed this card:groupByon ajsonfield answers 500DATABASE_ERRORon PostgreSQL, one merged group on memory, and one group per serialized value on SQLite #20783 (thejsongroupByparent) and [spec/drivers]AggregationNode.distinctis honoured by the in-memory fallback and ignored by every SQL face — one query, two numbers (ADR-0049) #6815 (closed;AggregationNode.distincthonoured by one face). Neither is these two shapes.Dedupe words:
groupBy multiple select postgres 500·group by multi-value field json column·count_distinct json field postgres 500·aggregate field type compatibility count_distinct jsonGenerated by Claude Code