JSP+SPRING+ORACLE 三层web系统, 运行一段时间之后时常抛出 “Refcursor值无效“的异常。 虽然SQL比较简单,一般不会有问题的情况, 但还是出现这种异常。 求助高手是不是ORACLE数据库的问题? 如何解决?例:
org.springframework.jdbc.UncategorizedSQLException: StatementCallback; uncategorized SQLException for SQL 
SQL state [null]; error code [17442]; Refcursor 值无效; nested exception is java.sql.SQLException: Refcursor 值无效
org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate

解决方案 »

  1.   

    是所有的oracle调用都报这错?
      

  2.   


    请参考http://hi.baidu.com/for_music_love/blog/item/94787a29934ddffa98250a40.html
      

  3.   


    你没有报ora错误,估计不一定是oracle自身的问题的。有可能是sql或者别的问题。
      

  4.   


    回楼上, 是不定时, 突然有问题,过了一阵之后,想再重现问题又不报错了! 所以应该也不是SQL的问题。  有的SQL很简单,就是select 也有可能出现这种问题。
      

  5.   


    看看oracle服务器的alert中有没有错误信息。这个有可能是oracle的bug吧。你的oracle版本?
      

  6.   

    oracle 9i 吧!  没有权利操控oracle服务器, 只能通过PL/SQL客户端
      

  7.   

    问题解决! This error message is probably due to a bug in the Oracle JDBC driver. 
    A number of product issues can be found on metalink. 
    The best thing to do is to upgrade to the latest Oracle JDBC thin driver. 
    This error message might also occur when a large database transaction is currently executing, but the thread timed-out. 
    If this is the case, see if your application server is set up to timeout inactive threads and make sure your network is 
    reliable and not setup to close inactive TCP connections. This looks to be a JDBC related issue. Which version of the Database and which JDBC driver are you using? There was a 
    bug in the thin JDBC driver which caused this exception when dealing with Clobs and UTF8 characters (2858085). Try 
    updating to the latest driver versions and see if the problem persists.