Commit ce2a02a
committed
Emit APPROX_COUNT_DISTINCT as the distinct_count_approx runtime name
PPLBuiltinOperators.DISTINCT_COUNT_APPROX created its SqlAggFunction with the
runtime-resolution name "DISTINCT_COUNT_APPROX". The analytics-engine (DataFusion)
backend resolves aggregates by the Calcite/Substrait-standard name
APPROX_COUNT_DISTINCT, so distinct_count_approx() failed to bind on the analytics
route. Emit APPROX_COUNT_DISTINCT instead.
The Java field name stays DISTINCT_COUNT_APPROX (the PPL function name); only the
resolution string changes. The OpenSearch V3 path is unaffected — it overrides this
operator via the external HyperLogLog registration in OpenSearchExecutionEngine
(whose name is unchanged), so explain output and execution on that path are
identical (verified). The analytics-route binding is completed by
opensearch-project/OpenSearch#22013 (APPROX_COUNT_DISTINCT -> approx_distinct).
Per Sandesh Kumar.
Signed-off-by: Kai Huang <ahkcs@amazon.com>1 parent c8bc773 commit ce2a02a
1 file changed
Lines changed: 5 additions & 1 deletion
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
521 | 521 | | |
522 | 522 | | |
523 | 523 | | |
524 | | - | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
525 | 529 | | |
526 | 530 | | |
527 | 531 | | |
| |||
0 commit comments