zoukankan      html  css  js  c++  java
  • 如何将字符串利用正则表达式转换为列值

    select
    null as MARK_ID,
    t2.table_name as TABLE_NAME,
    remark.field as FIELD_NAME,
    1 as MARK_TYPE,
    t2.table_name as CLASS_NAME,
    123 as CLASS_ID,
    '重要数据缺失' as REMARK1,
    null as REMARK2,
    null as STATE,
    null as CREATOR,
    null as CREATE_TIME,
    null as INVALID_PERSON,
    null as INVALID_TIME,
    null as LAST_MODIFY_PERSON,
    null as LAST_MODIFY_TIME,
    t2.field_show_name||'缺失' as REMARK,
    null as OPERATE_TYPE
    from (with Field as (select 'FLOORCOUNT/BLDONFLOCOUNT/BLDUNDFLOCOUNT/ROOMCOUNT/BLDFINISHDATE/BLDSTATE/BLDDESC/PROSTATE/' Field from dual)
    select regexp_substr(Field,'[^/]+',1,rownum) Field from Field
    connect by rownum<=length(regexp_replace(Field,'[^/]+'))) remark
    left join sys_enumeration t2 on t2.field_name=remark.Field
    where t2.table_name='BUILDING';

    --select * from sys_marks t;

  • 相关阅读:
    php utf-8
    thinkPHP--关于域名指向的问题
    PHP命名空间(Namespace)的使用详解
    thinkphp 动态配置
    枚举之称硬币
    5.7
    5.6
    5.5(OI一本通开始)
    5.4
    5.3
  • 原文地址:https://www.cnblogs.com/jxgzCHforever/p/8044523.html
Copyright © 2011-2022 走看看