diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/analyzer/UnboundTableSinkCreator.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/analyzer/UnboundTableSinkCreator.java index fd70401f25..e1c771b6a4 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/analyzer/UnboundTableSinkCreator.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/analyzer/UnboundTableSinkCreator.java @@ -111,10 +111,18 @@ public class UnboundTableSinkCreator { return new UnboundIcebergTableSink<>(nameParts, colNames, hints, partitions, dmlCommandType, Optional.empty(), Optional.empty(), plan); } + // TODO: we need to support insert into other catalog + try { + if (ConnectContext.get() != null) { + ConnectContext.get().getSessionVariable().enableFallbackToOriginalPlannerOnce(); + } + } catch (Exception e) { + // ignore this. + } throw new AnalysisException( - "Auto overwrite data to " + curCatalog.getClass().getSimpleName() + " is not supported." + (isOverwrite ? "insert overwrite" : "insert") + " data to " + curCatalog.getClass().getSimpleName() + + " is not supported." + (isAutoDetectPartition - ? " PARTITION(*) is only supported in overwrite partition for OLAP table" - : "")); + ? " PARTITION(*) is only supported in overwrite partition for OLAP table" : "")); } }