Skip to content
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

Allow to use () as the GROUP BY nothing #1347

Merged
merged 2 commits into from
Jul 22, 2024

Conversation

git-hulk
Copy link
Member

Currently, PostgreSQL supports using () as one of the group by elements that represent the meaning of nothing. Please refer to the GROUP BY Clause section in PostgreSQL.

This PR will close #1092.

@coveralls
Copy link

coveralls commented Jul 19, 2024

Pull Request Test Coverage Report for Build 10026634487

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 24 of 27 (88.89%) changed or added relevant lines in 2 files are covered.
  • 1322 unchanged lines in 5 files lost coverage.
  • Overall coverage increased (+0.04%) to 89.237%

Changes Missing Coverage Covered Lines Changed/Added Lines %
tests/sqlparser_common.rs 19 22 86.36%
Files with Coverage Reduction New Missed Lines %
tests/sqlparser_clickhouse.rs 4 98.45%
src/ast/query.rs 93 86.07%
src/ast/mod.rs 333 81.39%
src/parser/mod.rs 401 93.32%
tests/sqlparser_common.rs 491 89.66%
Totals Coverage Status
Change from base Build 9944212602: 0.04%
Covered Lines: 27055
Relevant Lines: 30318

💛 - Coveralls

@git-hulk git-hulk force-pushed the feature/group-by-nothing branch from 69c5a7e to fa9d7d3 Compare July 19, 2024 11:10
Currently, PostgreSQL supports using `()` as one of the group by elements which
represent the meaning of nothing. Please refer to GROUP BY Clause
section in [PostgreSQL](https://www.postgresql.org/docs/16/sql-select.html).

This PR will close apache#1092.
@git-hulk git-hulk force-pushed the feature/group-by-nothing branch from fa9d7d3 to a74cc1f Compare July 19, 2024 11:13
@git-hulk
Copy link
Member Author

cc @iffyio

@git-hulk git-hulk requested a review from iffyio July 21, 2024 07:53
Copy link
Contributor

@iffyio iffyio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! cc @alamb

@git-hulk git-hulk changed the title Allow to use () as the GROUP BY nothing for PostgreSQL Allow to use () as the GROUP BY nothing Jul 22, 2024
Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@alamb alamb merged commit b27abf0 into apache:main Jul 22, 2024
10 checks passed
@alamb
Copy link
Contributor

alamb commented Jul 22, 2024

Thank you @git-hulk and @iffyio

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.

GROUP BY () not supported
4 participants