--从根查到叶
select * from t_table_shu t start with t.id = 1 connect by prior t.id = t.parent_id;
--从叶查到跟
select * from t_table_shu t start with t.id = 5 connect by prior t.id = t.parent_id;
prior 指的是一哪一方为根节点为根节点
--从根查到叶
select * from t_table_shu t start with t.id = 1 connect by prior t.id = t.parent_id;
--从叶查到跟
select * from t_table_shu t start with t.id = 5 connect by prior t.id = t.parent_id;
prior 指的是一哪一方为根节点为根节点