-
Recent Posts
Recent Comments
- yangtingkun on 非空字段空值对查询的影响
- Eric Zong on 非空字段空值对查询的影响
- Kamus on Oracle Ace Director
- 设置全局死锁优先级 | yangtingkun on RAC全局死锁检测时间
- ORA-600(krbounotread_noctx)错误 | yangtingkun on ORA-600(krboReadBitmap_badbitmap)错误
Archives
- December 2020
- February 2019
- December 2018
- November 2018
- October 2018
- July 2018
- June 2018
- May 2018
- July 2016
- July 2013
- June 2013
- November 2012
- October 2012
- September 2012
- August 2012
- July 2012
- June 2012
- May 2012
- April 2012
- March 2012
- February 2012
- January 2012
- December 2011
- November 2011
- October 2011
- September 2011
- August 2011
Categories
Meta
Tag Archives: RETURN
ORA-600(13030)错误
在ITPUB上看到的一个UPDATE RETURN引发的ORA-600错误。 告警日志中错误如下: Mon Jan 16 09:50:13 2012 Errors IN file /DATA/dir1/app/oracle/admin/moyzkf1/udump/moyzkf1_ora_27801.trc: ORA-00600: internal error code, arguments: [13030], [1], [], [], [], [], [], []Mon Jan 16 09:50:13 2012 Errors in file /data/dir1/app/oracle/admin/moyzkf1/udump/moyzkf1_ora_27801.trc: ORA-00600: internal error code, arguments: [13030], [1], … Continue reading
JDBC使用INSERT RETURN语句报错ORA-439
在给客户开发人员讲解LOB列的访问方式后,开发人员尝试在JDBC中使用包含RETURN的INSERT语句,但是出现了ORA-439错误。 检查后发现客户的程序使用的还是PreparedStatement语句,而RETURNING语句,则是Oracle扩展的SQL语法,因此在声明语句的时候必须使用OraclePreparedStatement方式进行声明。 除了修改SQL语句外,使用OraclePreparedStatement声明语句变量外,还需要注册输出参数,类似的代码如下: OraclePreparedStatement sqlstmt = (OraclePreparedStatement)conn.prepareStatement ("insert into t_lob values (?, ?, empty_clob()) returning contents into ?"); sqlstmt.setInt(1, 1); sqlstmt.setString(2, "a"); sqlstmt.registerReturnParameter(3, OracleTypes.CLOB); sqlstat.executeUpdate(); ResultSet resset = sqlstmt.getReturnResultSet(); IF (resset.next()) { CLOB contents = (CLOB)resset.getClob(2); … }OraclePreparedStatement sqlstmt = … Continue reading
Posted in ORACLE
Tagged getReturnResultSet, JDBC, lob, ORA-439, OraclePreparedStatement, registerReturnParameter, RETURN
Leave a comment