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
The following commit(s) were added to refs/heads/branch-2.0 by this push:
new 8eac3ab25eb [fix](Nereids) should only do bind relation in view
analyzer #28637 (#28642)
8eac3ab25eb is described below
commit 8eac3ab25eb0ee28d7bf12801414cc7ad3720618
Author: morrySnow <[email protected]>
AuthorDate: Tue Dec 19 19:38:43 2023 +0800
[fix](Nereids) should only do bind relation in view analyzer #28637 (#28642)
---
.../main/java/org/apache/doris/analysis/CreateTableAsSelectStmt.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git
a/fe/fe-core/src/main/java/org/apache/doris/analysis/CreateTableAsSelectStmt.java
b/fe/fe-core/src/main/java/org/apache/doris/analysis/CreateTableAsSelectStmt.java
index 3019117942a..4e9ca525e08 100644
---
a/fe/fe-core/src/main/java/org/apache/doris/analysis/CreateTableAsSelectStmt.java
+++
b/fe/fe-core/src/main/java/org/apache/doris/analysis/CreateTableAsSelectStmt.java
@@ -88,11 +88,11 @@ public class CreateTableAsSelectStmt extends DdlStmt {
queryStmt.getResultExprs().get(i).getSrcSlotRef().getDesc().setColumn(columnCopy);
}
if (Config.enable_date_conversion) {
- if (queryStmt.getResultExprs().get(i).getType() == Type.DATE) {
+ if (queryStmt.getResultExprs().get(i).getType().isDate()) {
Expr castExpr =
queryStmt.getResultExprs().get(i).castTo(Type.DATEV2);
queryStmt.getResultExprs().set(i, castExpr);
}
- if (queryStmt.getResultExprs().get(i).getType() ==
Type.DATETIME) {
+ if (queryStmt.getResultExprs().get(i).getType().isDatetime()) {
Expr castExpr =
queryStmt.getResultExprs().get(i).castTo(Type.DATETIMEV2);
queryStmt.getResultExprs().set(i, castExpr);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]