Skip to content

[fix] correct column names in aggregate model doc examples#3670

Merged
morningman merged 3 commits into
apache:masterfrom
boluor:fix-aggregate-doc-example-columns
May 20, 2026
Merged

[fix] correct column names in aggregate model doc examples#3670
morningman merged 3 commits into
apache:masterfrom
boluor:fix-aggregate-doc-example-columns

Conversation

@boluor
Copy link
Copy Markdown
Contributor

@boluor boluor commented May 18, 2026

Summary

Fixes two code-example errors in the aggregate data model doc (table-design/data-model/aggregate.md):

  1. example_tbl_agg output mismatch — the SELECT * FROM example_tbl_agg result header showed last_visit_date / max_dwell_time, but the table DDL defines those columns as last_visit_dt / max_dwell. Corrected the output header to match the DDL.

  2. aggstate non-existent columns — the table aggstate is defined with columns k1, v1, v2, but the "retain intermediate results" section used non-existent k2 / k3 in sum_union / sum_merge / group_concat_union / group_concat_merge. Corrected to v1 / v2 (the earlier merge example already correctly uses v2).

Applied across all affected versions (EN: next + 2.0/2.1/3.x/4.x; ZH: next + 2.1/3.x/4.x).

Test plan

  • Verified example_tbl_agg DDL column names vs the SELECT * output header
  • Verified aggstate DDL columns (k1, v1, v2) vs the queries; sum_* maps to the SUM column v1, group_concat_* maps to the agg_state<group_concat> column v2
  • Verified ASCII output-table alignment after the rename

Two example errors in the aggregate data model doc:
- The `SELECT * FROM example_tbl_agg` output header used `last_visit_date`
  and `max_dwell_time`, but the table is defined with `last_visit_dt` and
  `max_dwell`.
- The `aggstate` table is defined with columns `k1, v1, v2`, but the
  intermediate-result section queried non-existent `k2` / `k3`. Corrected
  to `v1` / `v2`.

Applied across all affected EN and Chinese versions.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
boluor added 2 commits May 19, 2026 17:04
The CI pipeline no longer builds these legacy versions, so changes there
cannot be merged. Restore those files to their base state.
The previous commit's git-add-all unintentionally included two untracked
working files. Remove them from the PR.
@morningman morningman merged commit be05553 into apache:master May 20, 2026
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants