You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[finding] analytics: a cube / dataset dimension on a json field, compiled by NativeSQLStrategy, answers one group per serialized document on SQLite and 500 on PostgreSQL; the engine door #20783 closes does not see it #20807
Filing gate: ① a product defect with a measured reach:. Finding class (a). reach:AnalyticsService.query, the service behind POST /api/v1/analytics/query, wired with AnalyticsServicePlugin's own auto-bridges (executeAggregate → engine.aggregate, executeRawSql → engine.execute). Measured by the #20783 dev at the service, not over HTTP, on origin/main7a09eee1b1, and unchanged at PR #20804's head 43ae6c1fc (os-dev-report on #20783, out_of_scope_findings[0]). 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) as the sibling card triage 5905038653 on #20783 directed ("folded in only if the same door serves it; otherwise it becomes a sibling card"). ⛔ Filed bare: routing and grading belong to triage. ⛔ Not a claim. Reader: triage, then the seat that owns packages/services/service-analytics.
What happens
A cube dimension sql: 'meta' over a json field:
on the SQL drivers, the query goes through NativeSQLStrategy: engine.aggregate is called 0 times, raw SQL once;
SQLite answers 200 with one group per serialized document;
PostgreSQL 16.13 answers 500 DATABASE_ERROR.
Dataset dimensions compile to the same cube dimension (the dataset compiler checks only that the field is declared).
PR #20804 (#20783) refuses groupBy on a structured-JSON field at engine.aggregate with INVALID_FIELD / 400. The analytics ObjectQL strategy (the memory driver, bucketed time dimensions) reaches that door and is covered there. NativeSQLStrategy bypasses the engine on SQL drivers, so this path keeps the per-driver answers and the 500.
Pins on SQLite and PostgreSQL through /api/v1/analytics/query, with a text dimension control.
Noted by the same dev, for the same card: in the stand-in wiring the native-SQL path returned PostgreSQL's count as a string ('2') where SQLite returned a number (observed only).
Dedupe
mcp__github__search_issues, repo-scoped, open and closed, in the act that filed this card:
Dedupe words: analytics native sql dimension json field postgres 500 · cube dimension structured json group by · NativeSQLStrategy GROUP BY json column
Filing gate: ① a product defect with a measured
reach:. Finding class (a).reach:AnalyticsService.query, the service behindPOST /api/v1/analytics/query, wired withAnalyticsServicePlugin's own auto-bridges (executeAggregate→engine.aggregate,executeRawSql→engine.execute). Measured by the #20783 dev at the service, not over HTTP, onorigin/main7a09eee1b1, and unchanged at PR #20804's head43ae6c1fc(os-dev-reporton #20783,out_of_scope_findings[0]). 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) as the sibling card triage 5905038653 on #20783 directed ("folded in only if the same door serves it; otherwise it becomes a sibling card"). ⛔ Filed bare: routing and grading belong to triage. ⛔ Not a claim. Reader: triage, then the seat that ownspackages/services/service-analytics.What happens
A cube dimension
sql: 'meta'over ajsonfield:NativeSQLStrategy:engine.aggregateis called 0 times, raw SQL once;DATABASE_ERROR.Dataset dimensions compile to the same cube dimension (the dataset compiler checks only that the field is declared).
PR #20804 (#20783) refuses
groupByon a structured-JSON field atengine.aggregatewithINVALID_FIELD/ 400. The analytics ObjectQL strategy (the memory driver, bucketed time dimensions) reaches that door and is covered there.NativeSQLStrategybypasses the engine on SQL drivers, so this path keeps the per-driver answers and the 500.Scope for whoever takes it (⛔ not a ruling)
groupByon ajsonfield answers 500DATABASE_ERRORon PostgreSQL, one merged group on memory, and one group per serialized value on SQLite #20783's, at the analytics door: a dimension on a structured-JSON field is refusedINVALID_FIELD/ 400 naming the cube member the caller wrote (not the engine'sgroupBy[0]position), before any SQL is built. ⛔ Never a 500./api/v1/analytics/query, with atextdimension control.'2') where SQLite returned a number (observed only).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 is the engine half; analytics: an authored cube'spublic,refreshKey,format,granularitiesand descriptions take effect (8 keys) #20282, analytics: any member's inline dataset query replaces an authored cube for every user until restart, even when the query itself is refused 403 #20356, driver-sql on PostgreSQL: the nativeaggregatereturnscount/sum/avgas strings ("n":"1","total":"20.000…"), sohaving { n: { $in: [2] } }keeps no group on PostgreSQL alone, where memory, SQLite and PG's rows path keep c1, c2 #20335, service-analytics: the object-form analyticswhereskips the shared comparand-TYPE face, so a plain-object / Map / oversized-bigint comparand is bound as JSON text on the native path while the FilterArray spelling and the engine refuse 400 #20035, Analytics: a dataset dimension on a dotted relationship path (crm_account.industry) renders raw stored values — the same field as a local dimension renders its option labels #5144, [17.0-rc2验收] analytics: 不存在的 dimension 500(泄漏 SQL / SQLITE_ERROR)而不是 400 指名字段 —— #4437 只给 measure 加了闸门,dimension 侧对称缺口仍在 #5520 and analytics: /analytics/query ignores record-level scoping — a member counts and reads dimension values of records they cannot read #4467 are other analytics positions (closed). None is a dimension on ajsonfield.Dedupe words:
analytics native sql dimension json field postgres 500·cube dimension structured json group by·NativeSQLStrategy GROUP BY json columnGenerated by Claude Code