diff --git a/src/objit/include/objit/common/ob_item_type.h b/src/objit/include/objit/common/ob_item_type.h index 9af6559c06..9199542e13 100755 --- a/src/objit/include/objit/common/ob_item_type.h +++ b/src/objit/include/objit/common/ob_item_type.h @@ -2540,6 +2540,9 @@ typedef enum ObItemType // for vector index T_APPROX, + // select into outfile + T_BUFFER_SIZE, + T_PARTITION_EXPR, T_MAX //Attention: add a new type before T_MAX } ObItemType; diff --git a/src/sql/engine/basic/ob_select_into_op.cpp b/src/sql/engine/basic/ob_select_into_op.cpp index b77c7608a8..f89010ee6b 100644 --- a/src/sql/engine/basic/ob_select_into_op.cpp +++ b/src/sql/engine/basic/ob_select_into_op.cpp @@ -27,9 +27,10 @@ using namespace common; namespace sql { OB_SERIALIZE_MEMBER(ObSelectIntoOpInput, task_id_, sqc_id_); -OB_SERIALIZE_MEMBER((ObSelectIntoSpec, ObOpSpec), into_type_, user_vars_, - outfile_name_, field_str_, line_str_, closed_cht_, is_optional_, select_exprs_, is_single_, - max_file_size_, escaped_cht_, cs_type_, parallel_); +OB_SERIALIZE_MEMBER((ObSelectIntoSpec, ObOpSpec), into_type_, user_vars_, outfile_name_, + field_str_, // FARM COMPAT WHITELIST FOR filed_str_: renamed + line_str_, closed_cht_, is_optional_, select_exprs_, is_single_, max_file_size_, + escaped_cht_, cs_type_, parallel_, file_partition_expr_, buffer_size_); int ObSelectIntoOp::inner_open() diff --git a/src/sql/engine/basic/ob_select_into_op.h b/src/sql/engine/basic/ob_select_into_op.h index 6e86f03b83..4a85c4d793 100644 --- a/src/sql/engine/basic/ob_select_into_op.h +++ b/src/sql/engine/basic/ob_select_into_op.h @@ -66,7 +66,9 @@ public: is_single_(true), max_file_size_(DEFAULT_MAX_FILE_SIZE), escaped_cht_(), - parallel_(1) + parallel_(1), + file_partition_expr_(NULL), + buffer_size_(DEFAULT_BUFFER_SIZE) { cs_type_ = ObCharset::get_system_collation(); } @@ -74,9 +76,10 @@ public: ObItemType into_type_; common::ObFixedArray user_vars_; common::ObObj outfile_name_; - common::ObObj field_str_; + common::ObObj field_str_; // FARM COMPAT WHITELIST FOR filed_str_: renamed common::ObObj line_str_; - common::ObObj closed_cht_; + // 431以下版本select into无法并行执行, 不会序列化算子, 修改closed_cht_类型不会导致升级兼容性问题 + common::ObObj closed_cht_; // FARM COMPAT WHITELIST FOR closed_cht_: change type bool is_optional_; common::ObFixedArray select_exprs_; bool is_single_; @@ -84,7 +87,10 @@ public: common::ObObj escaped_cht_; common::ObCollationType cs_type_; int64_t parallel_; + sql::ObExpr* file_partition_expr_; + int64_t buffer_size_; static const int64_t DEFAULT_MAX_FILE_SIZE = 256LL * 1024 * 1024; + static const int64_t DEFAULT_BUFFER_SIZE = 1LL * 1024 * 1024; }; class ObSelectIntoOp : public ObOperator