ORACLE 使用通配符进行字符串截取

ORACLE 使用通配符进行字符串截取

select
regexp_substr('aa--a(1-23),b---b(32---1)','[^(,)]+',1,1) as col1,
regexp_substr('aa--a(1-23),b---b(32---1)','[^(,)]+',1,2) as col2,
regexp_substr('aa--a(1-23),b---b(32---1)','[^(,)]+',1,3) as col3,
regexp_substr('aa--a(1-23),b---b(32---1)','[^(,)]+',1,4) as col4
from dual;

posted @ 2019-09-24 14:40  LoveSnowBaby  阅读(420)  评论(0编辑  收藏  举报