二则 ORA-01722: invalid number错误的处理,substr to_char之间的区别。连接符号错误 + ||
2023-09-11 14:15:13 时间
Select to_char(loginDate,'yyyy') as sYear, Count(1) as iCount From l_log where operation='登录'
and InitFlag=1 Group By to_char(loginDate,'yyyy')
> ORA-01722: invalid number
sql语句改为:
Select substr(loginDate,1,4) as sYear, Count(1) as iCount From l_log where operation='登录'
and InitFlag=1 Group By substr(loginDate,1,4)
问题解决
还有一种是字符连接符号错误导致,oracle连接字符要用“||”不能用“+”
and ('','' + ListUser + '','' like %s and iStat <> -1)
改为
and ('','' || ListUser || '','' like %s and iStat <> -1)
问题解决
相关文章
- MyBatis错误--Invalid bound statement (not found)
- Maven 错误 :The POM for com.xxx:jar:0.0.1-SNAPSHOT is invalid, transitive dependencies (if any) will not be available
- Dubbo启动时qos-server can not bind localhost:22222错误解决
- js奇葩错误 字符串传递问题
- Android开发错误总结
- Java实现 LeetCode 278 第一个错误的版本
- centos网卡错误Device eth0 does not seem to be present
- mysql添加DATETIME类型字段导致Invalid default value错误的问题
- 【刷题】面筋-网络-无效链接,死链接,错误链接
- 错误消息“Conversion factors are invalid”的准确抛出位置
- 使用 describe命令 进行 Kubernetes pod 错误排查
- SAP Fiori Application Generator 在 Visual Studio Code 启动时遇到的错误消息
- SAP OData错误消息:Invalid format (return structure): Property Name ‘Guid‘, Property Value ‘000000
- Microsoft Office 2010 取消弹出宏安全性设置错误的提示
- 成功解决./nvidia-installer: invalid option: "‐‐no‐opengl‐files" ERROR: Invalid commandline, please run `
- ORA-00942:表或视图不存在 低级错误一例
- git使用过程中遇到的错误
- 【错误记录】编译 Linux 内核报错 ( /bin/sh: 1: flex: not found )
- Win10 无法加载操作系统,关键系统驱动程序丢失或错误 蓝屏错误代码0xc000007b
- 违例控制:解决错误
- 一次错误使用 go-cache 导致出现的线上问题
- 成功解决./nvidia-installer: invalid option: "‐‐no‐opengl‐files" ERROR: Invalid commandline, please run `
- AC上百度网盘做了策略可以下载不能上传 但是网页访问不了出现NET:ERR_CERT_AUTHORITY_INVALID 错误