登录
注册
开源
企业版
高校版
搜索
帮助中心
使用条款
关于我们
开源
企业版
高校版
私有云
模力方舟
登录
注册
9月20日,Gitee × 模力方舟来成都了!聚焦 AI 应用在开发范式、算力架构、交互设计、硬件选型等跨场景创新实践,点击立即报名~
代码拉取完成,页面将自动刷新
开源项目
>
数据库相关
>
数据库服务
&&
捐赠
捐赠前请先登录
取消
前往登录
扫描微信二维码支付
取消
支付完成
支付提示
将跳转至支付宝完成支付
确定
取消
Watch
不关注
关注所有动态
仅关注版本发行动态
关注但不提醒动态
442
Star
1.5K
Fork
1.8K
openGauss
/
openGauss-server
代码
Issues
961
Pull Requests
165
Wiki
统计
流水线
服务
质量分析
Jenkins for Gitee
腾讯云托管
腾讯云 Serverless
悬镜安全
阿里云 SAE
Codeblitz
SBOM
我知道了,不再自动展开
更新失败,请稍后重试!
移除标识
内容风险标识
本任务被
标识为内容中包含有代码安全 Bug 、隐私泄露等敏感信息,仓库外成员不可访问
【测试类型:SQL功能】【测试版本:6.0.0】【支持用ROWTYPE给游标赋值】包中proc调用其他包中参数为cursor%rowtype的proc,挂库,产生core
已验收
#IAINT6
缺陷
songfei
创建于
2024-08-08 11:14
【测试类型:SQL功能】【测试版本:6.0.0】【支持用ROWTYPE给游标赋值】包中proc调用其他包中参数为cursor%rowtype的proc,挂库,产生core 【操作系统和硬件信息】(查询命令: cat /etc/system-release, uname -a): Kylin Linux Advanced Server release V10 (Sword) Linux localhost.localdomain 4.19.90-24.4.v2101.ky10.aarch64 #1 SMP Mon May 24 14:45:37 CST 2021 aarch64 aarch64 aarch64 GNU/Linux 【测试环境】(单机):单机 【被测功能】:游标 【测试类型】:SQL功能 【数据库版本】(查询命令: gaussdb -V): gaussdb (openGauss 6.0.0 build f9b53221) compiled at 2024-08-07 00:16:32 commit 0 last mr B026 【操作步骤】(请填写详细的操作步骤): ``` --开启参数 set behavior_compat_options='allow_procedure_compile_check'; drop table if exists t_CurRowtype_Use_Case0007_1; create table t_CurRowtype_Use_Case0007_1(col1 varchar(30),col2 varchar(30)); insert into t_CurRowtype_Use_Case0007_1 values ('col1_a', 'col2_aa'); insert into t_CurRowtype_Use_Case0007_1 values ('col1_b', 'col2_bb'); drop table if exists t_CurRowtype_Use_Case0007_2; create table t_CurRowtype_Use_Case0007_2(col1 varchar(30),col2 varchar(30)); create or replace package pac_CurRowtype_Use_Case0007_5 is cursor cur1 is select col1,col2 from t_CurRowtype_Use_Case0007_1; var1 cur1%rowtype; procedure p_CurRowtype_Use_Case0007_5(a cur1%rowtype); end pac_CurRowtype_Use_Case0007_5; / create or replace package body pac_CurRowtype_Use_Case0007_5 is procedure p_CurRowtype_Use_Case0007_5(a cur1%rowtype) is begin var1.col1:='pack5_proc_col1'; var1.col2:='pack5_proc_col2'; insert into t_CurRowtype_Use_Case0007_2 values(var1.col1,var1.col2); end; end pac_CurRowtype_Use_Case0007_5; / create or replace package pac_CurRowtype_Use_Case0007_6 is cursor cur1 is select col1,col2 from t_CurRowtype_Use_Case0007_1; var1 cur1%rowtype; procedure p_CurRowtype_Use_Case0007_6; end pac_CurRowtype_Use_Case0007_6; / create or replace package body pac_CurRowtype_Use_Case0007_6 is procedure p_CurRowtype_Use_Case0007_6 is begin open cur1; fetch cur1 into var1; pac_CurRowtype_Use_Case0007_5.p_CurRowtype_Use_Case0007_5(var1); end; end pac_CurRowtype_Use_Case0007_6; / call pac_CurRowtype_Use_Case0007_6.p_CurRowtype_Use_Case0007_6();--挂库 ``` 【预期输出】: 调用成功 【实际输出】: 产生corefile 【原因分析】: 1. 这个问题的根因 2. 问题推断过程 3. 还有哪些原因可能造成类似现象 4. 该问题是否有临时规避措施 5. 问题解决方案 6. 预计修复问题时间 【日志信息】(请附上日志文件、截图、coredump信息): ``` warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available. Core was generated by `/opt/ShenTongGS/app/bin/gaussdb -D /opt/ShenTongGS/data/db1'. #0 0x0000aaadba14365c in sys_waitpid(int, int*, int) () [Current thread is 1 (LWP 2608834)] (gdb) bt #0 0x0000aaadba14365c in sys_waitpid(int, int*, int) () #1 0x0000aaadba144a58 in BBOX_GetClonePidResult(int, BBOX_ListParams*, int) () #2 0x0000aaadba144d98 in BBOX_GetAllThreads(GET_THREAD_TYPE, void (*)(void*), void*, int (*)(void (*)(void*), void*, int, int*, std::__va_list), ...) () #3 0x0000aaadba13bbfc in BBOX_CreateCoredump () #4 0x0000aaadba1463c8 in ?? () #5 <signal handler called> #6 0x0000aaadba95905c in ?? () #7 0x0000aaadbacbc1b0 in ?? () #8 0x0000aaadbacd6960 in plpgsql_exec_function(PLpgSQL_function*, FunctionCallInfoData*, bool, int*) () #9 0x0000aaadbaca4cd0 in plpgsql_inline_handler () #10 0x0000aaadb9f12cc8 in OidFunctionCall1Coll(unsigned int, unsigned int, unsigned long, bool) () #11 0x0000aaadbaca0bf0 in PackageInit(PLpgSQL_package*, bool, bool, bool) () #12 0x0000aaadbacb662c in plpgsql_pkg_compile(unsigned int, bool, bool, bool, bool) () #13 0x0000aaadbac9f7f4 in plpgsql_package_validator () #14 0x0000aaadbace0110 in ?? () #15 0x0000aaadbace1de0 in GetPackageDatum(List*, bool*) () #16 0x0000aaadbacb39d4 in plpgsql_pkg_add_unknown_var_to_namespace(List*) () #17 0x0000aaadbacaa5d4 in plpgsql_parse_dblword(char*, char*, PLwdatum*, PLcword*, int*) () #18 0x0000aaadbace0404 in plpgsql_yylex() () #19 0x0000aaadbad03260 in plpgsql_yyparse() () #20 0x0000aaadbacb00c0 in ?? () #21 0x0000aaadbacb2ab8 in plpgsql_compile(FunctionCallInfoData*, bool, bool) () #22 0x0000aaadbac9ef1c in plpgsql_validator () #23 0x0000aaadb9f12cc8 in OidFunctionCall1Coll(unsigned int, unsigned int, unsigned long, bool) () #24 0x0000aaadbac9fc1c in FunctionInPackageCompile(PLpgSQL_package*) () #25 0x0000aaadbaca06c4 in PackageInit(PLpgSQL_package*, bool, bool, bool) () #26 0x0000aaadbacb6964 in plpgsql_pkg_compile(unsigned int, bool, bool, bool, bool) () #27 0x0000aaadbac9f7f4 in plpgsql_package_validator () #28 0x0000aaadb9a808b4 in PackageInstantiation(unsigned int) () #29 0x0000aaadbaca227c in plpgsql_call_handler () #30 0x0000aaadba555e74 in ExecMakeTableFunctionResult(ExprState*, ExprContext*, tupleDesc*, bool, FunctionScanState*) () #31 0x0000aaadba5a9c68 in ?? () --Type <RET> for more, q to quit, c to continue without paging-- #32 0x0000aaadba53a578 in standard_ExecutorRun(QueryDesc*, ScanDirection, long) () #33 0x0000aaadba3b35a0 in ?? () #34 0x0000aaadba53a6b4 in ExecutorRun(QueryDesc*, ScanDirection, long) () #35 0x0000aaadba4bb760 in ?? () #36 0x0000aaadba4bd3a0 in PortalRun(PortalData*, long, bool, _DestReceiver*, _DestReceiver*, char*) () #37 0x0000aaadba4ad774 in ?? () #38 0x0000aaadba4b1fb8 in PostgresMain(int, char**, char const*, char const*) () #39 0x0000aaadba40abbc in ?? () #40 0x0000aaadba4388c0 in int GaussDbThreadMain<(knl_thread_role)1>(knl_thread_arg*) () #41 0x0000aaadba40ac50 in ?? () #42 0x0000ffff614787ac in ?? () from /usr/lib64/libpthread.so.0 #43 0x0000ffff613b60fc in ?? () from /usr/lib64/libc.so.6 ``` 【测试代码】:
【测试类型:SQL功能】【测试版本:6.0.0】【支持用ROWTYPE给游标赋值】包中proc调用其他包中参数为cursor%rowtype的proc,挂库,产生core 【操作系统和硬件信息】(查询命令: cat /etc/system-release, uname -a): Kylin Linux Advanced Server release V10 (Sword) Linux localhost.localdomain 4.19.90-24.4.v2101.ky10.aarch64 #1 SMP Mon May 24 14:45:37 CST 2021 aarch64 aarch64 aarch64 GNU/Linux 【测试环境】(单机):单机 【被测功能】:游标 【测试类型】:SQL功能 【数据库版本】(查询命令: gaussdb -V): gaussdb (openGauss 6.0.0 build f9b53221) compiled at 2024-08-07 00:16:32 commit 0 last mr B026 【操作步骤】(请填写详细的操作步骤): ``` --开启参数 set behavior_compat_options='allow_procedure_compile_check'; drop table if exists t_CurRowtype_Use_Case0007_1; create table t_CurRowtype_Use_Case0007_1(col1 varchar(30),col2 varchar(30)); insert into t_CurRowtype_Use_Case0007_1 values ('col1_a', 'col2_aa'); insert into t_CurRowtype_Use_Case0007_1 values ('col1_b', 'col2_bb'); drop table if exists t_CurRowtype_Use_Case0007_2; create table t_CurRowtype_Use_Case0007_2(col1 varchar(30),col2 varchar(30)); create or replace package pac_CurRowtype_Use_Case0007_5 is cursor cur1 is select col1,col2 from t_CurRowtype_Use_Case0007_1; var1 cur1%rowtype; procedure p_CurRowtype_Use_Case0007_5(a cur1%rowtype); end pac_CurRowtype_Use_Case0007_5; / create or replace package body pac_CurRowtype_Use_Case0007_5 is procedure p_CurRowtype_Use_Case0007_5(a cur1%rowtype) is begin var1.col1:='pack5_proc_col1'; var1.col2:='pack5_proc_col2'; insert into t_CurRowtype_Use_Case0007_2 values(var1.col1,var1.col2); end; end pac_CurRowtype_Use_Case0007_5; / create or replace package pac_CurRowtype_Use_Case0007_6 is cursor cur1 is select col1,col2 from t_CurRowtype_Use_Case0007_1; var1 cur1%rowtype; procedure p_CurRowtype_Use_Case0007_6; end pac_CurRowtype_Use_Case0007_6; / create or replace package body pac_CurRowtype_Use_Case0007_6 is procedure p_CurRowtype_Use_Case0007_6 is begin open cur1; fetch cur1 into var1; pac_CurRowtype_Use_Case0007_5.p_CurRowtype_Use_Case0007_5(var1); end; end pac_CurRowtype_Use_Case0007_6; / call pac_CurRowtype_Use_Case0007_6.p_CurRowtype_Use_Case0007_6();--挂库 ``` 【预期输出】: 调用成功 【实际输出】: 产生corefile 【原因分析】: 1. 这个问题的根因 2. 问题推断过程 3. 还有哪些原因可能造成类似现象 4. 该问题是否有临时规避措施 5. 问题解决方案 6. 预计修复问题时间 【日志信息】(请附上日志文件、截图、coredump信息): ``` warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available. Core was generated by `/opt/ShenTongGS/app/bin/gaussdb -D /opt/ShenTongGS/data/db1'. #0 0x0000aaadba14365c in sys_waitpid(int, int*, int) () [Current thread is 1 (LWP 2608834)] (gdb) bt #0 0x0000aaadba14365c in sys_waitpid(int, int*, int) () #1 0x0000aaadba144a58 in BBOX_GetClonePidResult(int, BBOX_ListParams*, int) () #2 0x0000aaadba144d98 in BBOX_GetAllThreads(GET_THREAD_TYPE, void (*)(void*), void*, int (*)(void (*)(void*), void*, int, int*, std::__va_list), ...) () #3 0x0000aaadba13bbfc in BBOX_CreateCoredump () #4 0x0000aaadba1463c8 in ?? () #5 <signal handler called> #6 0x0000aaadba95905c in ?? () #7 0x0000aaadbacbc1b0 in ?? () #8 0x0000aaadbacd6960 in plpgsql_exec_function(PLpgSQL_function*, FunctionCallInfoData*, bool, int*) () #9 0x0000aaadbaca4cd0 in plpgsql_inline_handler () #10 0x0000aaadb9f12cc8 in OidFunctionCall1Coll(unsigned int, unsigned int, unsigned long, bool) () #11 0x0000aaadbaca0bf0 in PackageInit(PLpgSQL_package*, bool, bool, bool) () #12 0x0000aaadbacb662c in plpgsql_pkg_compile(unsigned int, bool, bool, bool, bool) () #13 0x0000aaadbac9f7f4 in plpgsql_package_validator () #14 0x0000aaadbace0110 in ?? () #15 0x0000aaadbace1de0 in GetPackageDatum(List*, bool*) () #16 0x0000aaadbacb39d4 in plpgsql_pkg_add_unknown_var_to_namespace(List*) () #17 0x0000aaadbacaa5d4 in plpgsql_parse_dblword(char*, char*, PLwdatum*, PLcword*, int*) () #18 0x0000aaadbace0404 in plpgsql_yylex() () #19 0x0000aaadbad03260 in plpgsql_yyparse() () #20 0x0000aaadbacb00c0 in ?? () #21 0x0000aaadbacb2ab8 in plpgsql_compile(FunctionCallInfoData*, bool, bool) () #22 0x0000aaadbac9ef1c in plpgsql_validator () #23 0x0000aaadb9f12cc8 in OidFunctionCall1Coll(unsigned int, unsigned int, unsigned long, bool) () #24 0x0000aaadbac9fc1c in FunctionInPackageCompile(PLpgSQL_package*) () #25 0x0000aaadbaca06c4 in PackageInit(PLpgSQL_package*, bool, bool, bool) () #26 0x0000aaadbacb6964 in plpgsql_pkg_compile(unsigned int, bool, bool, bool, bool) () #27 0x0000aaadbac9f7f4 in plpgsql_package_validator () #28 0x0000aaadb9a808b4 in PackageInstantiation(unsigned int) () #29 0x0000aaadbaca227c in plpgsql_call_handler () #30 0x0000aaadba555e74 in ExecMakeTableFunctionResult(ExprState*, ExprContext*, tupleDesc*, bool, FunctionScanState*) () #31 0x0000aaadba5a9c68 in ?? () --Type <RET> for more, q to quit, c to continue without paging-- #32 0x0000aaadba53a578 in standard_ExecutorRun(QueryDesc*, ScanDirection, long) () #33 0x0000aaadba3b35a0 in ?? () #34 0x0000aaadba53a6b4 in ExecutorRun(QueryDesc*, ScanDirection, long) () #35 0x0000aaadba4bb760 in ?? () #36 0x0000aaadba4bd3a0 in PortalRun(PortalData*, long, bool, _DestReceiver*, _DestReceiver*, char*) () #37 0x0000aaadba4ad774 in ?? () #38 0x0000aaadba4b1fb8 in PostgresMain(int, char**, char const*, char const*) () #39 0x0000aaadba40abbc in ?? () #40 0x0000aaadba4388c0 in int GaussDbThreadMain<(knl_thread_role)1>(knl_thread_arg*) () #41 0x0000aaadba40ac50 in ?? () #42 0x0000ffff614787ac in ?? () from /usr/lib64/libpthread.so.0 #43 0x0000ffff613b60fc in ?? () from /usr/lib64/libc.so.6 ``` 【测试代码】:
评论 (
3
)
登录
后才可以发表评论
状态
已验收
待办的
已确认
已答复
已取消
挂起
修复中
已完成
待回归
测试中
已验收
负责人
未设置
雷紫薇
leiziwei0
负责人
协作者
+负责人
+协作者
huyinghao
yinghaohu
负责人
协作者
+负责人
+协作者
标签
未设置
项目
未立项任务
未立项任务
里程碑
未关联里程碑
未关联里程碑
Pull Requests
未关联
未关联
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
未关联
分支 (17)
标签 (29)
master
6.0.0
master_bak08271930
5.0.0
bugfix_0725
3.0.0
7.0.0-RC1
iud_dev
dev_board
5.1.0
kms
2.0.0
3.1.0
2.1.0
1.1.0
1.0.1
1.0.0
v6.0.2
v7.0.0-RC1
v6.0.1
v3.0.6
v6.0.0
v3.0.5B009
v5.0.3
v5.0.2
v6.0.0-RC1
v3.0.5
v5.0.1
v5.1.0
5.1.0
v5.0.0
v3.0.3
v3.1.1
v3.0.2
v3.1.0
v2.0.5
v3.0.1
v2.0.4
v2.0.3
v3.0.0
v2.1.0
v2.0.1
v2.0.0
v1.1.0
v1.0.1
v1.0.0
开始日期   -   截止日期
-
置顶选项
不置顶
置顶等级:高
置顶等级:中
置顶等级:低
优先级
不指定
严重
主要
次要
不重要
预计工期
(小时)
参与者(2)
C++
1
https://gitee.com/opengauss/openGauss-server.git
git@gitee.com:opengauss/openGauss-server.git
opengauss
openGauss-server
openGauss-server
点此查找更多帮助
搜索帮助
Git 命令在线学习
如何在 Gitee 导入 GitHub 仓库
Git 仓库基础操作
企业版和社区版功能对比
SSH 公钥设置
如何处理代码冲突
仓库体积过大,如何减小?
如何找回被删除的仓库数据
Gitee 产品配额说明
GitHub仓库快速导入Gitee及同步更新
什么是 Release(发行版)
将 PHP 项目自动发布到 packagist.org
仓库举报
回到顶部
登录提示
该操作需登录 Gitee 帐号,请先登录后再操作。
立即登录
没有帐号,去注册