[Fix](nereids) Fix month nullable datetimev2 literal binding#64459
Open
linrrzqqq wants to merge 1 commit into
Open
[Fix](nereids) Fix month nullable datetimev2 literal binding#64459linrrzqqq wants to merge 1 commit into
linrrzqqq wants to merge 1 commit into
Conversation
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Collaborator
Author
|
/review |
morrySnow
approved these changes
Jun 12, 2026
Contributor
|
PR approved by at least one committer and no changes requested. |
Contributor
|
PR approved by anyone and no changes requested. |
Contributor
There was a problem hiding this comment.
Review opinion: no blocking issues found.
Critical checkpoint conclusions:
- Goal/test: The PR fixes
month(nullable('...'))datetime-literal signature binding by changing theDATETIMEV2overload toDateTimeV2Type.WILDCARD, and adds a regression case inM.groovywith matchingM.outoutput. - Scope/focus: The code change is small and focused: one Month signature change plus one targeted regression query/result.
- Concurrency/lifecycle/config: Not applicable; this is FE expression binding metadata and a regression test only.
- Compatibility/FE-BE protocol/transactions/writes/persistence: Not applicable; no serialized format, thrift, transaction, or write-path behavior is changed.
- Parallel paths: Sibling date-part scalar functions such as
year,dayofmonth,week,hour,minute, andsecondalready useDateTimeV2Type.WILDCARD; I did not find another PR-scoped parallel path requiring the same change. - Error handling/conditions: No new error handling or conditional logic is introduced.
- Performance/observability: No material runtime overhead or new observability need; the change uses existing signature search and precision promotion behavior.
- Test result correctness: The added
qt_sqlis deterministic as a single-row scalar projection and the expected output matches the tested month/null results. - User focus: No additional review focus points were provided.
I did not run the regression suite locally in this review pass.
Collaborator
Author
|
run buildall |
Contributor
FE UT Coverage ReportIncrement line coverage |
Contributor
TPC-H: Total hot run time: 29387 ms |
Contributor
TPC-DS: Total hot run time: 169477 ms |
Contributor
FE Regression Coverage ReportIncrement line coverage |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related PR: #64127
Problem Summary:
nullable('...')string literals are unwrapped during signature search and coerced like bare literals. For:month(nullable('2021-12-31 12:23:34'))the argument is coerced to DATETIMEV2(6).
But Month declared its datetime overload as
DateTimeV2Type.SYSTEM_DEFAULT, which isDATETIMEV2(0).DATETIMEV2(6)does not match that narrow signature, so signature matching falls through to the DATEV2 overload and reports: