fix some optimizer stat bugs and some failed case

This commit is contained in:
wangt1xiuyi
2022-11-08 12:07:56 +00:00
committed by wangzelin.wzl
parent 44e79da7d2
commit b5c0373a99
8 changed files with 55 additions and 29 deletions

View File

@ -1619,7 +1619,8 @@ int ObDMLResolver::resolve_basic_table(const ParseNode &parse_tree, TableItem *&
} else { }
}
if (OB_SUCCESS == ret && sample_node != NULL && T_SAMPLE_SCAN == sample_node->type_) {
if (is_virtual_table(table_item->ref_id_)) {
if (is_virtual_table(table_item->ref_id_) &&
!is_oracle_mapping_real_virtual_table(table_item->ref_id_)) {
ret = OB_NOT_SUPPORTED;
LOG_USER_ERROR(OB_NOT_SUPPORTED, "sampling virtual table");
} else if (OB_FAIL(resolve_sample_clause(sample_node, table_item->table_id_))) {