ITPub博客

首页 > 数据库 > Oracle > ORA-00600: arguments: kkqcscpopn_Int:0

ORA-00600: arguments: kkqcscpopn_Int:0

原创 Oracle 作者:abstractcyj 时间:2015-09-30 16:20:29 0 删除 编辑
同事测试的时候,执行一个SELECT语句的时候出错了, 如图所示:


感觉上像是个Oracle的bug。
数据库版本:Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options

将 FULL JOIN改成LEFT JOIN没有出错, SQL语句

点击(此处)折叠或打开

  1. SELECT ac.checkno,
  2.        ac.compid,
  3.        ac.busno,
  4.        ac.wareid,
  5.        ac.makeno,
  6.        ac.stallno,
  7.        ac.batid,
  8.        (ac.invalidate) AS invalidate,
  9.        ac.accountqty,
  10.        CASE
  11.          WHEN tr.checkqty IS NULL THEN
  12.           0
  13.          ELSE
  14.           tr.checkqty
  15.        END AS checkqty,
  16.        ((CASE
  17.          WHEN tr.checkqty IS NULL THEN
  18.           0
  19.          ELSE
  20.           tr.checkqty
  21.        END) - ac.accountqty) AS plqty,
  22.        ac.purtax,
  23.        ac.avgpurprice AS accavgpurprice,
  24.        ac.avgpurprice,
  25.        (ac.purprice) AS accpurprice,
  26.        CASE
  27.          WHEN (tr.purprice) IS NULL THEN
  28.           0
  29.          ELSE
  30.           tr.purprice
  31.        END AS chepurprice,
  32.        (ac.saleprice) AS accsaleprice,
  33.        CASE
  34.          WHEN (tr.saleprice) IS NULL THEN
  35.           0
  36.          ELSE
  37.           tr.saleprice
  38.        END AS chesaleprice
  39.   FROM t_check_account ac
  40.   FULL JOIN (SELECT (h.checkno) AS checkno,
  41.                     wareid,
  42.                     MAX(makeno) makeno,
  43.                     batid,
  44.                     stallno,
  45.                     MAX(nvl(invalidate, '')) invalidate,
  46.                     SUM(nvl(checkqty, 0)) checkqty,
  47.                     MAX(purtax) purtax,
  48.                     MAX(purprice) purprice,
  49.                     MAX(saleprice) saleprice
  50.                FROM t_check_track_h h, t_check_track_d d
  51.               WHERE h.checkno = '150811001'
  52.                 AND h.checkno = d.checkno
  53.                 AND h.status = 1
  54.                 AND h.pageno = d.pageno
  55.               GROUP BY h.checkno, wareid, batid, stallno) tr
  56.     ON (ac.checkno = tr.checkno AND ac.wareid = tr.wareid AND
  57.        ac.batid = tr.batid AND ac.stallno = tr.stallno)
  58.  WHERE ac.checkno = '150811001'




解决方法:
修改隐含参数:_optimizer_cost_based_transformation
alter system set "_optimizer_cost_based_transformation"=OFF;


参考:http://blog.csdn.net/zzvnzz/article/details/7728329
         http://www.itpub.net/thread-1742242-2-1.html



来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/8520577/viewspace-1812519/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
曾从事java方向开发多年。近年已经转入数据库方向。主要擅长SQL优化,Oracle数据库问题诊断,Oracle备份与恢复等。服务于医药物流,医院等行业

注册时间:2010-01-26

  • 博文量
    555
  • 访问量
    833142