要是数据有限,倒是可以直接这样写
select * from (
select enbid, REGEXP_SUBSTR(v_list, '[^,]+', 1, lv) v_value
from (select 736021 as enbid, '5,51' as v_list from dual
union all
select 186168 as enbid, '53,49,50' as v_list from dual
union all
select 749409 as enbid, '7,68,51,11' as v_list from dual) a,
(SELECT LEVEL lv FROM dual CONNECT BY LEVEL < 32) b
WHERE b.lv <= 10 ) where v_value is not null;
————————————————
版权声明:本文为CSDN博主「老码伏枥驿站」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/jean852001/article/details/109338337