使用函数 regexp_split_to_table()
实例 aj 中的 ajsj 是多值代码 查询 为8的
SELECT t_ajsj.c_bh from
(
SELECT c_bh,regexp_split_to_table(c_ajsj,';') as ajcj from t_aj where c_ajsj is not null) t_ajsj where t_ajsj.ajcj = '8'
会把里面的多值代码拆成子表
使用函数 regexp_split_to_table()
实例 aj 中的 ajsj 是多值代码 查询 为8的
SELECT t_ajsj.c_bh from
(
SELECT c_bh,regexp_split_to_table(c_ajsj,';') as ajcj from t_aj where c_ajsj is not null) t_ajsj where t_ajsj.ajcj = '8'
会把里面的多值代码拆成子表
本文标题:怎么查询多值代码中的某一个(ArteryBase)
本文链接:https://www.haomeiwen.com/subject/zoskmttx.html
网友评论