fix the bug in creating mview with range or list partitions

This commit is contained in:
leftgeek
2024-03-20 09:26:40 +00:00
committed by ob-robot
parent 6c25e47e1f
commit e69c06c5d4

View File

@ -364,13 +364,15 @@ int ObDelUpdLogPlan::calculate_table_location_and_sharding(const ObDelUpdStmt &s
ret = OB_ALLOCATE_MEMORY_FAILED;
LOG_WARN("failed to allocate memory", K(sharding_info), K(ret));
} else {
const ObArray<ObRawExpr*> empty_filters;
const ObIArray<ObRawExpr*> &real_filters = get_optimizer_context().is_online_ddl() ? empty_filters : filters;
sharding_info = new(sharding_info) ObShardingInfo();
table_partition_info = new(table_partition_info) ObTablePartitionInfo(allocator_);
ObTableLocationType location_type = OB_TBL_LOCATION_UNINITIALIZED;
ObAddr &server = get_optimizer_context().get_local_server_addr();
table_partition_info->get_table_location().set_check_no_partition(stmt.is_merge_stmt());
if (OB_FAIL(calculate_table_location(stmt,
filters,
real_filters,
table_id,
ref_table_id,
part_ids,