trim(translate)和trim(regexp_replace)的使用 

trim(translate))的使用

 select 
     trim(
             translate
             (
                 t.DSR_NAME, '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ+_-=.`*~/!@#$%^&*()',' '
             )
          ) as bb 
from dam_dsr_relationb t

如果  DSR_NAME 这个字段里存有  2051李 

通过 trim(translate))后,得到的值为  李

 

 

 

trim(regexp_replace)的使用

trim(regexp_replace (a.DSR_NAME,'[[:digit:]]|[A-Z]|[a-z]|[[:punct:]]','')) as name2

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-05-02
  • 2021-07-16
  • 2022-01-28
  • 2022-12-23
  • 2022-12-23
  • 2021-09-30
猜你喜欢
  • 2021-06-22
  • 2021-05-27
  • 2021-08-23
  • 2021-08-20
  • 2022-01-15
  • 2021-07-17
相关资源
相似解决方案