Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Metz
oceanbase
提交
865c7006
O
oceanbase
项目概览
Metz
/
oceanbase
与 Fork 源项目一致
Fork自
oceanbase / oceanbase
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
oceanbase
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
865c7006
编写于
3月 03, 2022
作者:
L
ls0
提交者:
LINGuanRen
3月 03, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
adjust set op to reentrant
上级
47044f34
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
39 addition
and
4 deletion
+39
-4
src/sql/engine/set/ob_hash_except_op.cpp
src/sql/engine/set/ob_hash_except_op.cpp
+6
-1
src/sql/engine/set/ob_hash_intersect_op.cpp
src/sql/engine/set/ob_hash_intersect_op.cpp
+6
-1
src/sql/engine/set/ob_hash_set_op.cpp
src/sql/engine/set/ob_hash_set_op.cpp
+3
-1
src/sql/engine/set/ob_hash_set_op.h
src/sql/engine/set/ob_hash_set_op.h
+1
-0
src/sql/engine/set/ob_hash_union_op.cpp
src/sql/engine/set/ob_hash_union_op.cpp
+5
-0
src/sql/engine/set/ob_merge_except_op.cpp
src/sql/engine/set/ob_merge_except_op.cpp
+5
-0
src/sql/engine/set/ob_merge_intersect_op.cpp
src/sql/engine/set/ob_merge_intersect_op.cpp
+5
-0
src/sql/engine/set/ob_merge_set_op.cpp
src/sql/engine/set/ob_merge_set_op.cpp
+3
-1
src/sql/engine/set/ob_merge_set_op.h
src/sql/engine/set/ob_merge_set_op.h
+1
-0
src/sql/engine/set/ob_merge_union_op.cpp
src/sql/engine/set/ob_merge_union_op.cpp
+4
-0
未找到文件。
src/sql/engine/set/ob_hash_except_op.cpp
浏览文件 @
865c7006
...
...
@@ -97,7 +97,9 @@ int ObHashExceptOp::inner_get_next_row()
const
ObChunkDatumStore
::
StoredRow
*
store_row
=
nullptr
;
const
common
::
ObIArray
<
ObExpr
*>*
cur_exprs
=
nullptr
;
clear_evaluated_flag
();
if
(
first_get_left_
)
{
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
else
if
(
first_get_left_
)
{
if
(
OB_FAIL
(
is_left_has_row
(
left_has_row
)))
{
LOG_WARN
(
"failed to judge left has row"
,
K
(
ret
));
}
else
if
(
!
left_has_row
)
{
...
...
@@ -178,6 +180,9 @@ int ObHashExceptOp::inner_get_next_row()
LOG_WARN
(
"copy current row failed"
,
K
(
ret
));
}
}
if
(
OB_ITER_END
==
ret
)
{
iter_end_
=
true
;
}
return
ret
;
}
...
...
src/sql/engine/set/ob_hash_intersect_op.cpp
浏览文件 @
865c7006
...
...
@@ -84,7 +84,9 @@ int ObHashIntersectOp::inner_get_next_row()
const
ObHashPartCols
*
part_cols
=
nullptr
;
const
common
::
ObIArray
<
ObExpr
*>*
cur_exprs
=
nullptr
;
clear_evaluated_flag
();
if
(
first_get_left_
)
{
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
else
if
(
first_get_left_
)
{
if
(
OB_FAIL
(
is_left_has_row
(
left_has_row
)))
{
LOG_WARN
(
"failed to judge left has row"
,
K
(
ret
));
}
else
if
(
!
left_has_row
)
{
...
...
@@ -164,6 +166,9 @@ int ObHashIntersectOp::inner_get_next_row()
LOG_WARN
(
"copy current row failed"
,
K
(
ret
));
}
}
if
(
OB_ITER_END
==
ret
)
{
iter_end_
=
true
;
}
return
ret
;
}
...
...
src/sql/engine/set/ob_hash_set_op.cpp
浏览文件 @
865c7006
...
...
@@ -32,7 +32,8 @@ ObHashSetOp::ObHashSetOp(ObExecContext& exec_ctx, const ObOpSpec& spec, ObOpInpu
has_got_part_
(
false
),
profile_
(
ObSqlWorkAreaType
::
HASH_WORK_AREA
),
sql_mem_processor_
(
profile_
),
hp_infras_
()
hp_infras_
(),
iter_end_
(
false
)
{}
int
ObHashSetOp
::
inner_open
()
...
...
@@ -52,6 +53,7 @@ void ObHashSetOp::reset()
first_get_left_
=
true
;
has_got_part_
=
false
;
hp_infras_
.
reset
();
iter_end_
=
false
;
}
int
ObHashSetOp
::
inner_close
()
...
...
src/sql/engine/set/ob_hash_set_op.h
浏览文件 @
865c7006
...
...
@@ -58,6 +58,7 @@ protected:
ObSqlWorkAreaProfile
profile_
;
ObSqlMemMgrProcessor
sql_mem_processor_
;
ObHashPartInfrastructure
<
ObHashPartCols
,
ObHashPartStoredRow
>
hp_infras_
;
bool
iter_end_
;
};
}
// end namespace sql
...
...
src/sql/engine/set/ob_hash_union_op.cpp
浏览文件 @
865c7006
...
...
@@ -91,6 +91,8 @@ int ObHashUnionOp::inner_get_next_row()
LOG_WARN
(
"failed to get next row"
,
K
(
ret
));
}
first_get_left_
=
false
;
}
else
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
bool
got_row
=
false
;
bool
has_exists
=
false
;
...
...
@@ -145,6 +147,9 @@ int ObHashUnionOp::inner_get_next_row()
LOG_WARN
(
"copy current row failed"
,
K
(
ret
));
}
}
if
(
OB_ITER_END
==
ret
)
{
iter_end_
=
true
;
}
return
ret
;
}
...
...
src/sql/engine/set/ob_merge_except_op.cpp
浏览文件 @
865c7006
...
...
@@ -72,6 +72,9 @@ int ObMergeExceptOp::inner_get_next_row()
bool
break_outer_loop
=
false
;
const
ObIArray
<
ObExpr
*>*
left_row
=
NULL
;
clear_evaluated_flag
();
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
while
(
OB_SUCC
(
ret
)
&&
OB_SUCC
(
do_strict_distinct
(
*
left_
,
last_row_
.
store_row_
,
left_row
)))
{
break_outer_loop
=
right_iter_end_
;
while
(
OB_SUCC
(
ret
)
&&
!
right_iter_end_
)
{
...
...
@@ -120,6 +123,8 @@ int ObMergeExceptOp::inner_get_next_row()
}
else
if
(
OB_FAIL
(
last_row_
.
save_store_row
(
*
left_row
,
eval_ctx_
,
0
)))
{
LOG_WARN
(
"failed to save right row"
,
K
(
ret
));
}
}
else
if
(
OB_ITER_END
==
ret
)
{
iter_end_
=
true
;
}
return
ret
;
}
...
...
src/sql/engine/set/ob_merge_intersect_op.cpp
浏览文件 @
865c7006
...
...
@@ -71,6 +71,9 @@ int ObMergeIntersectOp::inner_get_next_row()
int
cmp
=
0
;
bool
break_outer_loop
=
false
;
const
ObIArray
<
ObExpr
*>*
left_row
=
NULL
;
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
clear_evaluated_flag
();
while
(
OB_SUCC
(
ret
)
&&
OB_SUCC
(
do_strict_distinct
(
*
left_
,
last_row_
.
store_row_
,
left_row
)))
{
while
(
OB_SUCC
(
ret
)
&&
!
right_iter_end_
)
{
...
...
@@ -111,6 +114,8 @@ int ObMergeIntersectOp::inner_get_next_row()
}
else
if
(
OB_FAIL
(
last_row_
.
save_store_row
(
*
left_row
,
eval_ctx_
,
0
)))
{
LOG_WARN
(
"failed to save right row"
,
K
(
ret
));
}
}
else
if
(
OB_ITER_END
==
ret
)
{
iter_end_
=
true
;
}
return
ret
;
}
...
...
src/sql/engine/set/ob_merge_set_op.cpp
浏览文件 @
865c7006
...
...
@@ -28,7 +28,8 @@ ObMergeSetOp::ObMergeSetOp(ObExecContext& exec_ctx, const ObOpSpec& spec, ObOpIn
alloc_
(
ObModIds
::
OB_SQL_MERGE_GROUPBY
,
OB_MALLOC_NORMAL_BLOCK_SIZE
,
OB_SERVER_TENANT_ID
,
ObCtxIds
::
WORK_AREA
),
last_row_
(
alloc_
),
cmp_
(),
need_skip_init_row_
(
false
)
need_skip_init_row_
(
false
),
iter_end_
(
false
)
{}
int
ObMergeSetOp
::
inner_open
()
...
...
@@ -57,6 +58,7 @@ int ObMergeSetOp::rescan()
last_row_
.
reset
();
alloc_
.
reset
();
need_skip_init_row_
=
false
;
iter_end_
=
false
;
if
(
OB_FAIL
(
ObOperator
::
rescan
()))
{
LOG_WARN
(
"failed to rescan"
,
K
(
ret
));
}
...
...
src/sql/engine/set/ob_merge_set_op.h
浏览文件 @
865c7006
...
...
@@ -73,6 +73,7 @@ protected:
ObChunkDatumStore
::
LastStoredRow
<>
last_row_
;
Compare
cmp_
;
bool
need_skip_init_row_
;
bool
iter_end_
;
};
template
<
typename
T
>
...
...
src/sql/engine/set/ob_merge_union_op.cpp
浏览文件 @
865c7006
...
...
@@ -282,9 +282,13 @@ int ObMergeUnionOp::inner_get_next_row()
if
(
OB_ISNULL
(
get_next_row_func_
))
{
ret
=
OB_ERR_UNEXPECTED
;
LOG_ERROR
(
"get_next_row_func is NULL"
,
K
(
ret
));
}
else
if
(
iter_end_
)
{
ret
=
OB_ITER_END
;
}
else
if
(
OB_FAIL
((
this
->*
get_next_row_func_
)()))
{
if
(
OB_ITER_END
!=
ret
)
{
LOG_WARN
(
"get next row failed"
,
K
(
ret
));
}
else
{
iter_end_
=
true
;
}
}
return
ret
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录