From ab3e7c8e511783cb40a3037e2e6d5f4b3739fed4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 17 Oct 2024 03:45:47 +0000 Subject: [PATCH] chore: Update vendored sources to duckdb/duckdb@cc067e6b7db33f516437567cbc726536e34ed716 (#507) delay the rewrite of a large IN-clause into a MarkJoin on remote Filter-Scans (duckdb/duckdb#14266) Co-authored-by: krlmlr --- src/duckdb/src/function/table/version/pragma_version.cpp | 6 +++--- src/duckdb/src/optimizer/in_clause_rewriter.cpp | 7 +++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/duckdb/src/function/table/version/pragma_version.cpp b/src/duckdb/src/function/table/version/pragma_version.cpp index 980ab2495..828954a96 100644 --- a/src/duckdb/src/function/table/version/pragma_version.cpp +++ b/src/duckdb/src/function/table/version/pragma_version.cpp @@ -1,5 +1,5 @@ #ifndef DUCKDB_PATCH_VERSION -#define DUCKDB_PATCH_VERSION "2-dev199" +#define DUCKDB_PATCH_VERSION "2-dev204" #endif #ifndef DUCKDB_MINOR_VERSION #define DUCKDB_MINOR_VERSION 1 @@ -8,10 +8,10 @@ #define DUCKDB_MAJOR_VERSION 1 #endif #ifndef DUCKDB_VERSION -#define DUCKDB_VERSION "v1.1.2-dev199" +#define DUCKDB_VERSION "v1.1.2-dev204" #endif #ifndef DUCKDB_SOURCE_ID -#define DUCKDB_SOURCE_ID "d2dfc60906" +#define DUCKDB_SOURCE_ID "cc067e6b7d" #endif #include "duckdb/function/table/system_functions.hpp" #include "duckdb/main/database.hpp" diff --git a/src/duckdb/src/optimizer/in_clause_rewriter.cpp b/src/duckdb/src/optimizer/in_clause_rewriter.cpp index 36ddb11b0..880964f5f 100644 --- a/src/duckdb/src/optimizer/in_clause_rewriter.cpp +++ b/src/duckdb/src/optimizer/in_clause_rewriter.cpp @@ -6,12 +6,19 @@ #include "duckdb/planner/expression/bound_operator_expression.hpp" #include "duckdb/planner/operator/logical_column_data_get.hpp" #include "duckdb/planner/operator/logical_comparison_join.hpp" +#include "duckdb/planner/operator/logical_get.hpp" #include "duckdb/execution/expression_executor.hpp" namespace duckdb { unique_ptr InClauseRewriter::Rewrite(unique_ptr op) { if (op->children.size() == 1) { + if (op->children[0]->type == LogicalOperatorType::LOGICAL_GET) { + auto &get = op->children[0]->Cast(); + if (get.function.to_string && get.function.to_string(get.bind_data.get()) == "REMOTE") { + return op; + } + } root = std::move(op->children[0]); VisitOperatorExpressions(*op); op->children[0] = std::move(root);