Skip to content

[fix](docs) BITMAP_AGG / MAP_AGG example setup (dev + 3.x + 2.1)#3895

Merged
morningman merged 2 commits into
apache:masterfrom
boluor:fix/phantom-table-setup-aggregate-bitmap-map
Jun 3, 2026
Merged

[fix](docs) BITMAP_AGG / MAP_AGG example setup (dev + 3.x + 2.1)#3895
morningman merged 2 commits into
apache:masterfrom
boluor:fix/phantom-table-setup-aggregate-bitmap-map

Conversation

@boluor
Copy link
Copy Markdown
Contributor

@boluor boluor commented Jun 3, 2026

Adds the missing CREATE TABLE + INSERT setup so the BITMAP_AGG and MAP_AGG examples are runnable end-to-end.

  • bitmap-agg: dev + version-3.x + version-2.1 (EN + ZH). Includes the dev k5-overflow fix (k5 BIGINTVARCHAR(32): the INSERT carries values 18446744073709551615/616 that overflow BIGINT and would reject the whole row, leaving the table empty; BITMAP_AGG converts the string per its domain rule, <0 or >uint64max dropped).
  • map-agg: version-3.x + version-2.1 (EN + ZH), TPC-H nation (25 rows).

Verified end-to-end on fresh single-BE clusters (4.1.1 / 3.1.4 / 2.1.11 and local master daily build): every touched example reproduces the doc's printed output cell-for-cell.

This supersedes #3897 (the dev k5 fix is folded in here so BITMAP_AGG lives in one PR).

🤖 Generated with Claude Code

boluor and others added 2 commits June 3, 2026 01:05
…x/2.1

Both pages' examples query tables the page never creates
(test_bitmap_agg, nation), so readers hit "table does not exist". Add a
visible CREATE TABLE + INSERT before the first example on each page
(EN + ZH, version-3.x and version-2.1), reconstructed from each page's
own printed output. Verified end-to-end on live 3.1.4 and 2.1.11
clusters: every example reproduces the documented output exactly
(P5 F0 per page), including the BITMAP_AGG VARCHAR->BIGINT cast cases
and the MAP_AGG grouped map output.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The dev BITMAP_AGG page declares `k5 BIGINT` in its setup table but
inserts 18446744073709551615 and 18446744073709551616, which exceed the
BIGINT range. The whole INSERT is rejected, leaving the table empty, so
every example on the page fails.

Change `k5` to VARCHAR(32) (and quote its values) so the large values are
stored as written; BITMAP_AGG converts them and applies its own range
rule (values < 0 or > 18446744073709551615 are dropped), reproducing the
documented output. Verified end-to-end on a live master build: every
example passes (EN + ZH).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@boluor boluor changed the title [fix](docs) add table setup for BITMAP_AGG and MAP_AGG examples in 3.x/2.1 [fix](docs) BITMAP_AGG / MAP_AGG example setup (dev + 3.x + 2.1) Jun 3, 2026
@morningman morningman merged commit 6ff563c into apache:master Jun 3, 2026
3 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