8000 `count(distinct _row_id)` causing other `count(distinct ...)` producing wrong result · Issue #20187 · risingwavelabs/risingwave · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

count(distinct _row_id) causing other count(distinct ...) producing wrong result #20187

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
stdrc opened this issue Jan 16, 2025 · 0 comments
Open
Assignees
Labels
A-agg Area: Aggregate. type/bug Type: Bug. Only for issues.
Milestone

Comments

@stdrc
Copy link
Member
stdrc commented Jan 16, 2025

Describe the bug

No response

Error message/log

No response

To Reproduce

dev=> create table t (foo int, bar int);
CREATE_TABLE
dev=> insert into t values (1, 1), (2, 2), (1, 1);
INSERT 0 3
dev=> select count(foo), count(distinct foo) from t;
 count | count 
-------+-------
     3 |     2
(1 row)

dev=> select count(foo), count(distinct foo), count(distinct _row_id) from t;
 count | count | count 
-------+-------+-------
     3 |     1 |     3
             ^
           wrong
(1 row)

dev=> select count(foo), count(distinct foo), count(distinct bar) from t;
 count | count | count 
-------+-------+-------
     3 |     2 |     2
(1 row)

Expected behavior

No response

How did you deploy RisingWave?

No response

The version of RisingWave

No response

Additional context

No response

@stdrc stdrc added the type/bug Type: Bug. Only for issues. label Jan 16, 2025
@github-actions github-actions bot added this to the release-2.3 milestone Jan 16, 2025
@stdrc stdrc changed the title count(distinct _row_id) causing other count producing wrong result count(distinct _row_id) causing other count(distinct ...) producing wrong result Jan 16, 2025
@BugenZhao BugenZhao marked this as a duplicate of #20188 Jan 16, 2025
@stdrc stdrc added the A-agg Area: Aggregate. label May 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-agg Area: Aggregate. type/bug Type: Bug. Only for issues.
Projects
None yet
Development

No branches or pull requests

2 participants
0