diff --git a/src/sql/engine/cmd/ob_tenant_executor.cpp b/src/sql/engine/cmd/ob_tenant_executor.cpp index 70dc8209ac..47261ce603 100644 --- a/src/sql/engine/cmd/ob_tenant_executor.cpp +++ b/src/sql/engine/cmd/ob_tenant_executor.cpp @@ -624,9 +624,6 @@ int ObModifyTenantExecutor::execute(ObExecContext &ctx, ObModifyTenantStmt &stmt } else if (OB_FAIL(schema_guard.get_tenant_info( modify_tenant_arg.tenant_schema_.get_tenant_name_str(), tenant_schema))) { LOG_WARN("fail to get tenant info", K(ret)); - } else if (OB_ISNULL(tenant_schema)) { - ret = OB_ERR_UNEXPECTED; - LOG_WARN("error unexpected, tenant schema must not be NULL", K(ret)); } if (OB_FAIL(ret)) { } else if (-1 != stmt.get_progressive_merge_num()) { @@ -641,9 +638,15 @@ int ObModifyTenantExecutor::execute(ObExecContext &ctx, ObModifyTenantStmt &stmt } else if (OB_FAIL(modify_progressive_merge_num_for_all_tenants(ctx, stmt.get_progressive_merge_num()))) { LOG_WARN("modify_progressive_merge_num_for_tables failed", K(ret)); } - } else if (OB_FAIL(modify_progressive_merge_num_for_tenant(ctx, tenant_schema->get_tenant_id(), stmt.get_progressive_merge_num()))) { - LOG_WARN("fail to modify progressive merge num for tenant", K(ret), "tenant_id", tenant_schema->get_tenant_id()); - } + } else if (OB_ISNULL(tenant_schema)) { + ret = OB_ERR_UNEXPECTED; + LOG_WARN("error unexpected, tenant schema must not be NULL", KR(ret)); + } else if (OB_FAIL(modify_progressive_merge_num_for_tenant(ctx, tenant_schema->get_tenant_id(), stmt.get_progressive_merge_num()))) { + LOG_WARN("fail to modify progressive merge num for tenant", K(ret), "tenant_id", tenant_schema->get_tenant_id()); + } + } else if (OB_ISNULL(tenant_schema)) { + ret = OB_ERR_UNEXPECTED; + LOG_WARN("error unexpected, tenant schema must not be NULL", KR(ret)); } else if (stmt.get_modify_tenant_arg().alter_option_bitset_.has_member(obrpc::ObModifyTenantArg::ENABLE_EXTENDED_ROWID)) { if (OB_FAIL(enable_extended_rowid_for_tenant_tables(ctx, tenant_schema->get_tenant_id()))) { LOG_WARN("fail to enable extended rowid for tenant tables", K(ret), "tenant_id", tenant_schema->get_tenant_id());