java.lang.Exception: OALL8 处于不一致状态

java.lang.Exception: OALL8 处于不一致状态

java.lang.Exception: 无法从套接字读取更多的数据

java.lang.Exception: 无法从套接字读取更多的数据
03:41:55,611 ERROR [STDERR] at com.iss.itreasury.settlement.remind.process.RemindProcess.StartRemindProcess(RemindProcess.java:1181)
03:41:55,611 ERROR [STDERR] at com.iss.itreasury.settlement.remind.process.RemindTask.run(RemindTask.java:39)
03:41:55,611 ERROR [STDERR] at java.util.TimerThread.mainLoop(Timer.java:512)
03:41:55,611 ERROR [STDERR] at java.util.TimerThread.run(Timer.java:462)
03:41:55,918 ERROR [STDERR] java.sql.SQLException: OALL8 处于不一致状态
03:41:55,918 ERROR [STDERR] at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
03:41:55,918 ERROR [STDERR] at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)
03:41:55,918 ERROR [STDERR] at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:208)
03:41:55,918 ERROR [STDERR] at oracle.jdbc.driver.T4C8Oall.marshal(T4C8Oall.java:352)
03:41:55,918 ERROR [STDERR] at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:199)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:796)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1031)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.T4CPreparedStatement.executeMaybeDescribe(T4CPreparedStatement.java:836)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1124)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3285)
03:41:55,919 ERROR [STDERR] at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3329)
03:41:55,919 ERROR [STDERR] at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeQuery(WrappedPreparedStatement.java:236)
03:41:55,919 ERROR [STDERR] at com.iss.itreasury.loan.awake.bizlogic.Awake.getAllAwakeContract(Awake.java:2093)
03:41:55,919 ERROR [STDERR] at com.iss.itreasury.loan.awake.bizlogic.AwakeTask.run(AwakeTask.java:43)
03:41:55,919 ERROR [STDERR] at java.util.TimerThread.mainLoop(Timer.java:512)
03:41:55,919 ERROR [STDERR] at java.util.TimerThread.run(Timer.java:462)
03:41:55,919 ERROR [STDERR] java.lang.Exception: OALL8 处于不一致状态
03:41:55,919 ERROR [STDERR] at com.iss.itreasury.loan.awake.bizlogic.Awake.getAllAwakeContract(Awake.java:2181)
03:41:55,919 ERROR [STDERR] at com.iss.itreasury.loan.awake.bizlogic.AwakeTask.run(AwakeTask.java:43)
03:41:55,919 ERROR [STDERR] at java.util.TimerThread.mainLoop(Timer.java:512)
03:41:55,919 ERROR [STDERR] at java.util.TimerThread.run(Timer.java:462)

【OALL8 处于不一致状态】问题是因为ojdbc.jar的版本的问题,需保证中间件中使用的jar包和开发环境中的jar包保持一致。
我的是把ojdbc.jar更新至最新版本后解决该问题。

【java.lang.Exception: 无法从套接字读取更多的数据】这个问题在百度的时候说法比较多,我测试以后,发现我的是因为sql语句的问题。
参照http://simon-fish.iteye.com/blog/1059068这篇博客的说法,将SQL语句中复杂的关联查询都换成left join的方式进行关联,问题解决。

注:上面的博客中,博主用的是子查询导致该问题,我的是用的左连接关联查询(加号(+)的方式关联)导致了该问题。修改为left join方式连接查询后问题解决。

此处记录备忘,如有遇到相同问题的,可从这些方面着手排查问题的原因。

附最近ojdbc.jar下载地址:http://download.csdn.net/detail/yang_lover/9455401

展开阅读全文

执行长sql 出现java.sql.SQLException: OALL8 处于不一致状态

01-10

在PL/SQL执行下面语句没有问题,但在java中执行会抛异常,实在找不出原因了,求救 大牛;rn异常如下:rnjava.sql.SQLException: 无法从套接字读取更多的数据rnsql如下:rn[code=sql] merge into scnf_month_fund t1rn using (select s.shopinfo_id,rn s.shop_type,rn p.pc_name,rn p.pc_code,rn m.name,rn m.idnum,rn m.bank_account,rn p.accounts_type,rn p.star_level,rn to_date('2013-01', 'yyyy-mm') pay_month,rn f.fundrn from qd_xx_shopinfo s, qd_xx_pcinfo p, qd_xx_pcmanager m,rn (select sum(t.final_pay) fund,t.pc_codern from (select p.pc_code,c.final_payrn from qd_xcjtx_tjtygdcj c,qd_xx_pcinfo_bak p,qd_xx_shopinfo shrn where c.belong_month = add_months(to_date('2013-01', 'yyyy-mm'),-1)rn and trunc(p.pcinfo_bak_date, 'mm') = add_months(c.belong_month,1)rn and c.pc_code = p.pc_codern and sh.shopinfo_id = p.shopinfo_idrn and p.is_valid = 1rn and sh.shop_type = 0rn union allrn select p.pc_code,c.final_payrn from qd_xcjtx_tjtysalecj c,qd_xx_pcinfo_bak p,qd_xx_shopinfo shrn where c.belong_month = add_months(to_date('2013-01', 'yyyy-mm'),-1)rn and trunc(p.pcinfo_bak_date, 'mm') = add_months(c.belong_month,1)rn and c.pc_code = p.pc_codern and sh.shopinfo_id = p.shopinfo_idrn and p.is_valid = 1rn and sh.shop_type = 0) trn group by t.pc_code) frn where f.pc_code = p.pc_codern and s.shopinfo_id = p.shopinfo_idrn and s.shop_type = 0rn and p.is_valid = 1rn and p.pcmanager_id = m.pcmanager_idrn union allrn select s.shopinfo_id,rn s.shop_type,rn p.pc_name,rn p.pc_code,rn m.name,rn m.idnum,rn m.bank_account,rn p.accounts_type,rn p.star_level,rn to_date('2013-01', 'yyyy-mm') pay_month,rn f.fundrn from qd_xx_shopinfo s, qd_xx_pcinfo p, qd_xx_pcmanager m,rn (select sum(t.final_pay) fund,t.shopinfo_idrn from (select sh.shopinfo_id,c.final_payrn from qd_xcjtx_tjtygdcj c,qd_xx_pcinfo_bak p,qd_xx_shopinfo shrn where c.belong_month = add_months(to_date('2013-01', 'yyyy-mm'),-1)rn and trunc(p.pcinfo_bak_date, 'mm') = add_months(c.belong_month,1)rn and c.pc_code = p.pc_codern and sh.shopinfo_id = p.shopinfo_idrn and p.is_valid = 1rn and sh.shop_type = 1rn union allrn select sh.shopinfo_id,c.final_payrn from qd_xcjtx_tjtysalecj c,qd_xx_pcinfo_bak p,qd_xx_shopinfo shrn where c.belong_month = add_months(to_date('2013-01', 'yyyy-mm'),-1)rn and trunc(p.pcinfo_bak_date, 'mm') = add_months(c.belong_month,1)rn and c.pc_code = p.pc_codern and sh.shopinfo_id = p.shopinfo_idrn and p.is_valid = 1rn and sh.shop_type = 1) trn group by t.shopinfo_id) frn where f.shopinfo_id = p.shopinfo_idrn and s.shopinfo_id = p.shopinfo_idrn and s.shop_type = 1rn and p.is_valid = 1rn and p.pc_code like '%_zd%'rn and p.pcmanager_id = m.pcmanager_id) t2rn on(t1.pc_code = t2.pc_code and t1.pay_month = t2.pay_month and t1.info_batch = '1' )rn when matched thenrn update set t1.tjtysubsity_fund = t2.fundrn when not matched then rn insert (shopinfo_id,shop_type,pc_name,pc_code,pcmanager,sfz_code,rn account_name,account_id,account_type,star_level,pay_month,info_batch,tjtysubsity_fund)rn values (t2.shopinfo_id,t2.shop_type,t2.pc_name,t2.pc_code,t2.name,t2.idnum,rn t2.name,t2.bank_account,t2.accounts_type,t2.star_level,t2.pay_month,'1',t2.fund)[/code] 论坛

没有更多推荐了,返回首页