This is an automated email from the ASF dual-hosted git repository. kxiao pushed a commit to branch branch-2.0 in repository https://gitbox.apache.org/repos/asf/doris.git
commit 22582d61b5621dc928373822aec72db443837b57 Author: jakevin <[email protected]> AuthorDate: Mon Jul 10 16:49:42 2023 +0800 fix: toCalendar should use Calendar.MONTH instead MONDAY (#21665) --- .../main/java/org/apache/doris/nereids/types/coercion/DateLikeType.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/types/coercion/DateLikeType.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/types/coercion/DateLikeType.java index 7defd1b61f..18b207fdaf 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/types/coercion/DateLikeType.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/types/coercion/DateLikeType.java @@ -32,7 +32,7 @@ public abstract class DateLikeType extends PrimitiveType { int year = date / 10000; Calendar calendar = Calendar.getInstance(); calendar.set(Calendar.YEAR, year); - calendar.set(Calendar.MONDAY, month); + calendar.set(Calendar.MONTH, month); calendar.set(Calendar.DAY_OF_MONTH, day); return calendar; } --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
