人员账号所属权限模块

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 部门编号,人员编号

相关推荐
xiaoxiang96098 分钟前
Git 分支同步实战:`merge -X theirs` 与完全合并方案
数据库·git·elasticsearch
GoppViper36 分钟前
用户测试如何提升SEO转化率?四种实操方法与案例解析
数据库·经验分享
先吃饱再说1 小时前
后端开发绕不开的 SQL:从建表、查询到索引优化,一篇讲透
数据库·后端·sql
敲代码的小小酥1 小时前
InfluxDB时序数据库(续)
数据库·时序数据库
智购科技自动贩卖机2 小时前
自动售货机嵌入式系统Go语言开发实践:从资源受限设备到RTOS协程调度的工程化之路
大数据·linux·数据库·人工智能·yolo·架构·golang
SelectDB2 小时前
2026 年 Apache Doris 和 StarRocks 怎么选?一篇更接近真实选型的对比
大数据·数据库·数据分析
祢真伟大2 小时前
DM8 归档日志挖掘导致 TEMP 表空间不释放的问题排查
数据库
qq_485015212 小时前
MyBatis-Plus 3.x FieldStrategy 作用
java·数据库·mybatis
lhldsg2 小时前
课程排课系统实战指南:从数据库设计到算法调优全流程解析
java·数据库·算法·小程序
丰锋ff2 小时前
数据库操作的一些相关命令
数据库