From 7e05d64743690a065036d01e15f75f3c7c4d7cfc Mon Sep 17 00:00:00 2001 From: obdev Date: Sat, 10 Feb 2024 02:59:02 +0000 Subject: [PATCH] fix bug, select failed when get column group --- src/share/schema/ob_table_schema.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/share/schema/ob_table_schema.cpp b/src/share/schema/ob_table_schema.cpp index ca7c44095c..8d23c44692 100644 --- a/src/share/schema/ob_table_schema.cpp +++ b/src/share/schema/ob_table_schema.cpp @@ -8688,9 +8688,9 @@ int ObTableSchema::get_column_group_index(const share::schema::ObColumnParam &pa ret = OB_ERR_UNEXPECTED; LOG_WARN("Unexpected column group type", K(ret), KPC(column_group_arr_[i])); } - } else if (1 < cg_column_cnt) { + } else if (1 < cg_column_cnt || column_group_arr_[i]->get_column_group_type() != ObColumnGroupType::SINGLE_COLUMN_GROUP) { iter_cg_idx++; - // ignore column group with more than one column + // ignore column group with more than one column or not each column group cg } else if (OB_ISNULL(cg_column_ids = column_group_arr_[i]->get_column_ids())) { ret = OB_ERR_UNEXPECTED; LOG_WARN("Unexpected error for null column ids", K(ret), KPC(column_group_arr_[i]));