You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "boluor (via GitHub)" <gi...@apache.org> on 2026/05/30 04:35:47 UTC

[PR] [fix](doc) v2.1/v3.x: correct ARRAY_ENUMERATE_UNIQ multi-array example result [doris-website]

boluor opened a new pull request, #3859:
URL: https://github.com/apache/doris-website/pull/3859

   ## Problem
   
   The multi-array example
   
   ```sql
   select array_enumerate_uniq([1,1,1,1,1],[2,1,2,1,2],[3,1,3,1,3]);
   ```
   
   is documented as `[1, 1, 2, 1, 3]`, which is **wrong**. `array_enumerate_uniq` returns, for each position, the ordinal of that position's tuple among equal tuples. The by-position tuples here are:
   
   ```
   (1,2,3) (1,1,1) (1,2,3) (1,1,1) (1,2,3)
   ```
   
   so the ordinals are `[1, 1, 2, 2, 3]` — the 4th position is the **2nd** occurrence of `(1,1,1)`, not the 1st. The doc had `1` at the 4th position.
   
   ## Scope
   
   Present (and fixed) in **v2.1 EN, v3.x EN, v3.x ZH**. Already correct in **v2.1 ZH, v4.x, and dev**, so those are untouched.
   
   This page's other examples are correct (checked by hand and on cluster): the single-array example `[1,2,3,1,2,3] → [1,1,1,2,2,2]` and the description prose `[1,2,1,1,2],[2,1,2,2,1] → [1,1,2,3,2]`.
   
   > Note: this is a "both languages wrong" case on v3.x, so a cross-language diff doesn't reveal it — it was caught by a native v2.1 sweep where v2.1 ZH happened to already be correct.
   
   ## Cluster verification (Doris 3.1.4-rc02 and 2.1.11-rc01, identical)
   
   ```
   mysql> select array_enumerate_uniq([1, 1, 1, 1, 1], [2, 1, 2, 1, 2], [3, 1, 3, 1, 3]);
   +-------------------------------------------------------------------------+
   | array_enumerate_uniq([1, 1, 1, 1, 1], [2, 1, 2, 1, 2], [3, 1, 3, 1, 3]) |
   +-------------------------------------------------------------------------+
   | [1, 1, 2, 2, 3]                                                         |
   +-------------------------------------------------------------------------+
   ```
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


Re: [PR] [fix](doc) v2.1/v3.x: correct ARRAY_ENUMERATE_UNIQ multi-array example result [doris-website]

Posted by "morningman (via GitHub)" <gi...@apache.org>.
morningman merged PR #3859:
URL: https://github.com/apache/doris-website/pull/3859


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org