人员账号所属权限模块

select distinct

a.编码 as 部门编号,

a.名称 部门,

B.编号 as 人员编号,

b.姓名,

d.用户名,

substr(t.角色, 4, 20) as 角色,t.标题, t.说明,t.功能

from 部门表 a,

人员表 b,

部门人员 c,

上机人员表 d,

dba_role_privs e,

dba_roles f,

(select g.角色, h.序号, h.标题, h.说明, h.系统,G.功能

from (select distinct 系统, 序号, 角色,功能 from zltools.zlrolegrant) g,

zltools.zlprograms h

where g.序号 = h.序号

and h.系统 is not null) t

where e.granted_role = f.role

and f.role like '%ZL_%'

and a.id = c.部门id

and b.id = c.人员id

and b.id = d.人员id

and e.grantee = d.用户名

and f.role = t.角色

and C.缺省=1

And C.部门ID /*B0*/is not null/*E0*/

order by 部门编号,人员编号

相关推荐
kirs_ur9 小时前
ECC & LDPC — SSD 的数据卫士
服务器·数据库·性能优化
是三一seven10 小时前
Sql注入基础
数据库·安全·网络安全
Sirens.10 小时前
MySQL表设计进阶-约束范式连接索引与事务
android·数据库·mysql
字节跳动开源12 小时前
火山引擎开源 Agent 驱动的搜索自迭代技术
数据库·开源·agent
Oo大司命oO14 小时前
藏在正则表达式里的陷阱
数据库·mysql·正则表达式
_oP_i15 小时前
mysql统计数据库使用存储大小
数据库
会编程的土豆15 小时前
MySQL 入门:库、表、行、主键是什么
linux·数据库·网络协议·http
jjjava2.015 小时前
系统日志:从入门到精通的完整指南
网络·数据库
写代码的强哥15 小时前
云原生数据库与传统数据库相比“新”在哪里
数据库·云原生·架构
许彰午16 小时前
05-十分钟读懂AWR报告
oracle