关键字
KingbaseES、系统表、存储
概述
\df+ function_name 查看自己创建的function,并显示function内容;
\df+ procedure_name 查看自己创建的procedure,并显示procedure内容
\dpkg+ package_name 查看自己创建的package,并显示package内容
查看系统表内PLSQL对象以及内容:
select oid,prosrc from pg_proc where proname='';
select * from sys_package where pkgname='';
select proname,proargnames,prosrc from pg_proc where oid in (select objid from pg_depend where refobjid = (select oid from pg_type where typname = '') and deptype = 'i');
select oid,proname,prosrc from sys_proc where oid = (select tgfoid from pg_triggers where tgname = '');
示例
\df+ procedure_name
select oid,prosrc from pg_proc where proname='';
select proname,proargnames,prosrc from pg_proc where oid in (select objid from pg_depend where refobjid = (select oid from pg_type where typname = '') and deptype = 'i');
select oid,proname,prosrc from sys_proc where oid = (select tgfoid from pg_triggers where tgname = '');
\dpkg+ package_name
select * from sys_package where pkgname='';