morrySnow commented on code in PR #66288:
URL: https://github.com/apache/doris/pull/66288#discussion_r3811253879
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/parser/LogicalPlanBuilder.java:
##########
@@ -3215,8 +3212,7 @@ public Expression
visitArithmeticBinary(ArithmeticBinaryContext ctx) {
throw new ParseException("Only supported: " + Operator.ADD
+ " and " + Operator.SUBTRACT, ctx);
}
Interval interval = (Interval) right;
Review Comment:
so, this is a bug fix for date arithmetic functions? if it is, please push
another PR to fix it serperately.
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/literal/Interval.java:
##########
@@ -126,6 +126,26 @@ public boolean isDateTimeUnit() {
return isDateTimeUnit;
}
+ /** Whether this unit combines multiple time fields, such as DAY_HOUR
or YEAR_MONTH. */
+ public boolean isCompound() {
Review Comment:
`isCompound` would be better as a member variable of TimeUnit.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]