摘要: 表名“TH_PRIVILEGE”查询语句:with tt(l,ID,NAME,PID) as(select l=case when PID IS null then 1 when PID IS not null then 2 end,ID,NAME,PID from TH_PRIVILEGE union allselect l=case when t1.PID IS null then 1 when t1.PID IS not null then 2 end,t1.ID,t1.NAME,t1.PID from TH_PRIVILEGE t1inner join tt b on t1.ID=.. 阅读全文