oracle正则表达式

--查询字段最后两位是否是字母

select * from table1 where 1=1 and REGEXP_SUBSTR( Trim(字段名) ,'([[:alpha:]]{2})$') is not null

-- 也可以查询出来看结果

select REGEXP_SUBSTR( Trim(字段名) ,'([[:alpha:]]{2})$')  from table1 where 1=1 

posted @ 2023-10-20 09:32  二零一七  阅读(9)  评论(0编辑  收藏  举报