select distinct t2.fname as 子系统分组名称,s2.fname as 子系统名称,
o2.fname as 业务对象 ,e2.fcaption as 权限项组,p4.fname as 权限项 from t_SEC_ObjectTypePermission p inner join
T_SEC_PermissionObjectEntry p2 on p.fpermissionobjectid=p2.fitemid
inner join T_SEC_PERMISSIONITEM p3 on p2.FPermissionItemID=p3.FItemID --权限项
left join T_SEC_PERMISSIONITEM_l p4 on p3.FItemID=p4.FItemID and p4.FLOCALEID= 2052 --权限项多语言
inner join t_meta_objectType o1 on p.fobjecttypeid=o1.FID
left join t_meta_objectType_l o2 on p.FObjectTypeId= o2.FID and o2.FLOCALEID= 2052 --业务对象多语言
inner join t_meta_subsystem s1 on o1.FSUBSYSID = s1.FID --子系统
left join t_meta_subsystem_l s2 on s1.FID = s2.FID and s2.FLOCALEID= 2052 --子系统多语言
inner join T_META_TOPCLASS t1 on t1.FTOPCLASSID= s1.FTOPCLASSID --子系统分组(业务领域)
left join T_META_TOPCLASS_L t2 on t2.FTOPCLASSID= t1.FTOPCLASSID and t2.FLOCALEID= 2052 --子系统多语言
inner join T_META_FORMENUMITEM e1 on e1.fvalue=p3.fgroup and e1.fid='af6f30ae-8ad4-45d5-9fa9-6da06a690e2c'
left join T_META_FORMENUMITEM_l e2 on e2.fenumid=e1.fenumid and e2.FLOCALEID=2052
where o2.fname not like '%弃用%'
order by o2.fname,s2.fname,e2.fcaption
推荐阅读