甲骨文批量列转行逗号分隔

  

示例:

with  temp    (select  & # 39; 1、2、3 & # 39;, num,, & # 39;一个# 39;,names 得到双   union    select  & # 39; 4、5 & # 39;, num,, & # 39; b # 39; names 得到双   union    select  & # 39; 6、7 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 8 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 9、10 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 11、12 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 13、14 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 15、16 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 17、18 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 19、20 & # 39;, num,, & # 39; c # 39; names 得到双   union    select  & # 39; 21日,22日,23日,24日,25日,26日,27日,28日,29、30、31、32、33、34 & # 39;,num,, & # 39; c # 39; names 得到双   )   的select  regexp_substr (num & # 39; [^,] + & # 39;, 1, b.lv), order_num,名字   得到临时,(select  level  lv 得到dual  connect  by  level<=(select 马克斯(长度的(regexp_replace (num & # 39;[^,] + & # 39;)) + 1),得到临时)),b——用于分配行数(行数取最大的num分隔数)   的where  b.lv  & lt;=长度(regexp_replace (num & # 39; [^,] + & # 39;)) + 1, order  by  order_num


甲骨文批量列转行逗号分隔