oracle ORA-01722无效数字
2012-10-26 14:09
549 查看
我有一个表table_a 里面有一个字段field中保存了用户的编号,编号使用逗号隔开,例如:379,380,386,390,503我做查询select * from user where user_id in (379,380,386,390,503); 是正确的。 但是当我查询 select * from user where user_id in (select field from table_a where id = 1);时却报oracle ORA-01722无效数字
答:select * from user where INSTR( (select ',' || field || ',' from table_a where id = 1), ',' || TRIM(TO_CHAR(user_id )) || ',' ) > 0
答:select * from user where INSTR( (select ',' || field || ',' from table_a where id = 1), ',' || TRIM(TO_CHAR(user_id )) || ',' ) > 0
相关文章推荐
- oracle 无效数字ORA-01722:
- 【Oracle】ORA-01722:无效数字(控制文件最后一个字段)
- oracle to_namber之后报ora-01722:无效数字
- oracle排序报错“ORA-01722: 无效数字”处理
- ORACLE-023:令人烦恼的 ora-01722 无效数字
- ORACLE-023:令人烦恼的 ora-01722 无效数字
- 记一次 oracle ORA-01722: 无效数字 错误排查
- Oracle错误: ORA-01722 无效数字
- Oracle ORA-01722: 无效数字 处理方法
- oracle ORA-01722:无效数字 记录
- ORACLE隐式类型转换 ORA-01722: 无效数字
- Oracle 参数化更新数据时报错:Oracle ORA-01722: 无效数字
- ORA-01722:无效数字
- ORA-01722 无效数字
- ORA-01722: 无效数字
- ORA-01722:无效数字
- ORA-01722:无效数字
- PreparedStatement批量向数据库插入数据报了这个异常:java.sql.SQLException:ORA-01722: 无效数字
- ORA-01722: 无效数字
- 数据库-ORA-01722:无效数字