行转列以前的数据:函数
select * from tbname;
行转列以后的数据:spa
select pud, listagg(ud, ',') within group(order by null) as ud from tbname group by pud;
其中,code
listagg(ud, ',') within group(order by null)
为行转列函数,ud为须要转化的列blog
as ud
as ud 为给转后的列匿名一个新列名。it
完成。class