帮我看看这个oracle语句,select groupid,parentid,groupname,isleaf,description,sharerankid,statusid,corporationid,staffid,isactual,groupcount,level FROM (SELECT a.*,b.groupcount FROM teabgroup a,(SELECT groupid,count(*) groupcount FROM teabmembe
来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/17 11:46:38
帮我看看这个oracle语句,select groupid,parentid,groupname,isleaf,description,sharerankid,statusid,corporationid,staffid,isactual,groupcount,level FROM (SELECT a.*,b.groupcount FROM teabgroup a,(SELECT groupid,count(*) groupcount FROM teabmembe
帮我看看这个oracle语句,
select groupid,parentid,groupname,isleaf,description,sharerankid,
statusid,corporationid,staffid,isactual,groupcount,level
FROM (SELECT a.*,b.groupcount FROM teabgroup a,(
SELECT groupid,count(*) groupcount
FROM teabmember GROUP BY groupid) b
WHERE a.groupid=b.groupid(+) and a.corporationid = 0 )
START WITH parentid=0
CONNECT BY PRIOR groupid=parentid
声明这里面有个level字段在这两张表中是不存在的,一直不知道为什么.不存在也能查出来的.并且查出的结果就是level1或者level2的,为什么?
请问怎么个递归查询?是根据什么来递归的.根据我的某一个变量?
帮我看看这个oracle语句,select groupid,parentid,groupname,isleaf,description,sharerankid,statusid,corporationid,staffid,isactual,groupcount,level FROM (SELECT a.*,b.groupcount FROM teabgroup a,(SELECT groupid,count(*) groupcount FROM teabmembe
oracle中,递归查询的时候,level是个隐式变量,数字类型的
level:递归层数