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
[CALCITE-6343] Fix AS alias operator stripping MEASUREness from measures #3741
base: main
Are you sure you want to change the base?
Conversation
8cd7dd4
to
622a340
Compare
core/src/test/java/org/apache/calcite/sql/type/RelDataTypeSystemTest.java
Show resolved
Hide resolved
core/src/test/java/org/apache/calcite/test/SqlToRelConverterTest.java
Outdated
Show resolved
Hide resolved
622a340
to
b41526d
Compare
…lias operator When inferring the return type of an operator application, don't unwrap MEASURE types if the operator is an AS alias.
b41526d
to
2975087
Compare
I saw a failure with |
Quality Gate passedIssues Measures |
if (opBinding.getOperator().kind != SqlKind.AS | ||
&& isMeasure(returnType) | ||
&& returnType.getMeasureElementType() != null) { | ||
returnType = returnType.getMeasureElementType(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The checkerframework failure below does seem related to your change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's related to the change you asked me to make on your code, removing the not-null assertion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might need to add it back. Seems like it's messing something up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also I've found it can be a time-saver to try re-building before pushing new changes.
When inferring the return type of an operator application, don't unwrap MEASURE types if the operator is an AS alias.