时间:2021-07-01 10:21:17 帮助过:6人阅读
LISTAGG(XXX,XXX) WITHIN GROUP( ORDER BY XXX)
多行转为单行,并进行拼接
例:查询合肥分部及其上级的id,并进行拼接,逗号隔开
select listagg(id,‘,‘) within group (order by id) ids from (SELECT id FROM org START WITH name = ‘合肥分部‘ CONNECT BY id = PRIOR parent_id);
Oracle:listagg
标签:拼接 org div class ima acl 逗号 connect oracl