Oracle合并某一列

一.oracle11g使用listagg() within group()函数 

如图一

二 使用:select sname,ListAgg(to_char(hobby),',')  within group (order by sname)  as xhobby    from newtest group by sname,结果如下图

 

posted @ 2017-04-25 11:35  小痞子Yang  阅读(2831)  评论(0编辑  收藏  举报