SELECT SYS_CONNECT_BY_PATH(SE_ID, ' -> ') AS PATH, LEVEL, T.* FROM T_BDM_SALES_REPLACE T START WITH SE_ID = '1000004412' CONNECT BY PRIOR SE_ID = SOURCE_SE_ID;
Oracle查询层级关系的sql
最新推荐文章于 2024-08-16 17:02:33 发布
SELECT SYS_CONNECT_BY_PATH(SE_ID, ' -> ') AS PATH, LEVEL, T.* FROM T_BDM_SALES_REPLACE T START WITH SE_ID = '1000004412' CONNECT BY PRIOR SE_ID = SOURCE_SE_ID;