Skip to content

[BugFix] Fix analysis time nullability for ROLLUP keys (backport #76149)#76408

Closed
mergify[bot] wants to merge 1 commit into
branch-4.1from
mergify/bp/branch-4.1/pr-76149
Closed

[BugFix] Fix analysis time nullability for ROLLUP keys (backport #76149)#76408
mergify[bot] wants to merge 1 commit into
branch-4.1from
mergify/bp/branch-4.1/pr-76149

Conversation

@mergify

@mergify mergify Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Why I'm doing:

#75684 introduced a bug for GROUP BY ROLLUP / CUBE / GROUPING SETS produces NULLs in the grouping key columns, while SelectAnalyzer derives output field nullability solely from the expression itself (item.getExpr().isNullable(), i.e. the base column's nullability). This widening normally happens at the optimizer level, but due to ArrowFlight, the schema needs to be correct at analysis time.

What I'm doing:

Fix the bug for nullable columns when there are grouping clauses.
Fixes #issue

What type of PR is this:

  • BugFix
  • Feature
  • Enhancement
  • Refactor
  • UT
  • Doc
  • Tool

Does this PR entail a change in behavior?

  • Yes, this PR will result in a change in behavior.
  • No, this PR will not result in a change in behavior.

If yes, please specify the type of change:

  • Interface/UI changes: syntax, type conversion, expression evaluation, display information
  • Parameter changes: default values, similar parameters but with different default values
  • Policy changes: use new policy to replace old one, functionality automatically enabled
  • Feature removed
  • Miscellaneous: upgrade & downgrade compatibility, etc.

Checklist:

  • I have added test cases for my bug fix or my new feature
  • This pr needs user documentation (for new or modified features or behaviors)
    • I have added documentation for my new feature or new function
    • This pr needs auto generate documentation
  • This is a backport pr

Bugfix cherry-pick branch check:

  • I have checked the version labels which the pr will be auto-backported to the target branch
    • 4.1
    • 4.0
    • 3.5

This is an automatic backport of pull request #76149 done by [Mergify](https://mergify.com).

Signed-off-by: Christopher Sapinski <christopher.sapinski@celerdata.com>
(cherry picked from commit 0829123)

# Conflicts:
#	fe/fe-core/src/main/java/com/starrocks/sql/analyzer/SelectAnalyzer.java
@mergify mergify Bot added the conflicts label Jul 15, 2026
@mergify

mergify Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Cherry-pick of 0829123 has failed:

On branch mergify/bp/branch-4.1/pr-76149
Your branch is up to date with 'origin/branch-4.1'.

You are currently cherry-picking commit 0829123d37.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   fe/fe-core/src/test/java/com/starrocks/sql/analyzer/AnalyzeViewNullabilityTest.java

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   fe/fe-core/src/main/java/com/starrocks/sql/analyzer/SelectAnalyzer.java

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@wanpengfei-git wanpengfei-git enabled auto-merge (squash) July 15, 2026 06:42
@mergify mergify Bot closed this Jul 15, 2026
auto-merge was automatically disabled July 15, 2026 06:42

Pull request was closed

@mergify

mergify Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

@mergify[bot]: Backport conflict, please reslove the conflict and resubmit the pr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant