Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/bugfix-22' into bugfix-22
Browse files Browse the repository at this point in the history
  • Loading branch information
liugddx committed Feb 12, 2024
2 parents ae2501a + add5272 commit 4a199a7
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@
import org.apache.doris.nereids.trees.plans.commands.BatchInsertIntoTableCommand;
import org.apache.doris.nereids.trees.plans.commands.Command;
import org.apache.doris.nereids.trees.plans.commands.CreateTableCommand;
import org.apache.doris.nereids.trees.plans.commands.ExportCommand;
import org.apache.doris.nereids.trees.plans.commands.Forward;
import org.apache.doris.nereids.trees.plans.commands.InsertIntoTableCommand;
import org.apache.doris.nereids.trees.plans.commands.InsertOverwriteTableCommand;
Expand Down Expand Up @@ -503,8 +504,12 @@ public void execute(TUniqueId queryId) throws Exception {
}
boolean isInsertIntoCommand = parsedStmt != null && parsedStmt instanceof LogicalPlanAdapter
&& ((LogicalPlanAdapter) parsedStmt).getLogicalPlan() instanceof InsertIntoTableCommand;
boolean isExportCommand = parsedStmt != null && parsedStmt instanceof LogicalPlanAdapter
&& ((LogicalPlanAdapter) parsedStmt).getLogicalPlan() instanceof ExportCommand;

if (e instanceof NereidsException
&& !context.getSessionVariable().enableFallbackToOriginalPlanner && !isInsertIntoCommand) {
&& !context.getSessionVariable().enableFallbackToOriginalPlanner
&& (!isInsertIntoCommand || !isExportCommand)) {
LOG.warn("Analyze failed. {}", context.getQueryIdentifier(), e);
throw ((NereidsException) e).getException();
}
Expand Down

0 comments on commit 4a199a7

Please sign in to comment.