查看: 5724|回复: 2

[笔记] Solving a mysterious parse failure

[复制链接]
论坛徽章:
47
蒙奇·D·路飞
日期:2017-03-27 08:04:23马上有车
日期:2014-02-18 16:41:112014年新春福章
日期:2014-02-18 16:41:11一汽
日期:2013-09-01 20:46:27复活蛋
日期:2013-03-13 07:55:232013年新春福章
日期:2013-02-25 14:51:24ITPUB 11周年纪念徽章
日期:2012-10-09 18:03:322012新春纪念徽章
日期:2012-02-13 15:13:202012新春纪念徽章
日期:2012-02-13 15:13:202012新春纪念徽章
日期:2012-02-13 15:13:20
发表于 2014-3-4 05:23 | 显示全部楼层 |阅读模式
本帖最后由 Yong Huang 于 2014-3-4 11:16 编辑

On one of our 11.2.0.3 databases, a few sessions always increase their "parse count (failures)" statistic as viewed in v$sesstat. This was found in a routine session parse failure check with my OSSW tool:
http://yong321.freeshell.org/freeware/ossw.html

Initially I was trying to identify the failed SQL with SQL trace (event 10046). No SQL showed up in the trace file marked with PARSE ERROR. Then I set the event to certain specific error codes, such as 942 (for "table or view does not exist"), 904 (for "invalid identifier"), and a few others. Still no trace. Fortunately, there's one Oracle event designed to trace SQL parse failure

$ oerr ora 10035
10035, 00000, "Write parse failures to alert log file"
// *Cause:

Once I set that:

exec dbms_system.set_ev(<sid>, <serial#>, 10035, 1, '')

and wait till the session's "parse count (failures)" goes up, the database alert.log has this line

Thu Feb 27 11:17:20 2014
PARSE ERROR: ospid=27945, error=10980 for statement:
/* SQL Analyze(1313,0) */ insert into "APP_OWNER"."MLOG$_USERS" select * from "APP_OWNER"."MLOG$_USERS"^@

I would never have thought of ORA-10980 related to a parse failure. What is this error?

$ oerr ora 10980
10980, 00000, "prevent sharing of parsed query during Materialized View query generation"
// *Document: NO
// *Cause:   N/A.
// *Action:  Set this event only under the supervision of Oracle development.
// *Comment: Not for general purpose use.

It's actually an error code failling in the range of Oracle events, but it's reported as an error. A MOS search gives me documents 294513.1 and 1616695.1. They indicate that this error is related to materialized views and can be ignored. So I'll be happy to ignore it.

For more info about event 10035, please refer to Oracle note 1353015.1.

P.S. If any friend is using my old parse_failure.pl script, please switch to OSSW. Or at least stop using the unreliable -S option of parse_failure.pl and use event 10035 instead.
论坛徽章:
8
ITPUB十周年纪念徽章
日期:2011-11-01 16:25:512012新春纪念徽章
日期:2012-01-04 11:56:19现代
日期:2013-11-28 11:01:14马上加薪
日期:2014-03-31 10:53:18马上有钱
日期:2014-03-31 15:05:51优秀写手
日期:2014-04-26 05:59:55暖羊羊
日期:2015-03-04 14:53:002015年新春福章
日期:2015-03-06 11:58:18
发表于 2014-3-4 17:16 | 显示全部楼层
本帖最后由 Yong Huang 于 2014-3-4 09:24 编辑

Perfect!
I paid little attention to this value except when I check AWR. Thank you for letting me know this 10035 event.

使用道具 举报

回复
论坛徽章:
0
发表于 2014-3-7 11:17 | 显示全部楼层
thank you very much。

使用道具 举报

回复

您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

DTCC2020中国数据库技术大会 限时9.5折

【架构革新 高效可控】2020年8月17日~19日第十一届中国数据库技术大会将在北京隆重召开。

大会设置2大主会场,20+技术专场,将邀请超百位行业专家,重点围绕数据架构、AI与大数据、传统企业数据库实践和国产开源数据库等内容展开分享和探讨,为广大数据领域从业人士提供一场年度盛会和交流平台。

http://dtcc.it168.com


大会官网>>
TOP技术积分榜 社区积分榜 徽章 团队 统计 知识索引树 积分竞拍 文本模式 帮助
  ITPUB首页 | ITPUB论坛 | 数据库技术 | 企业信息化 | 开发技术 | 微软技术 | 软件工程与项目管理 | IBM技术园地 | 行业纵向讨论 | IT招聘 | IT文档
  ChinaUnix | ChinaUnix博客 | ChinaUnix论坛
CopyRight 1999-2011 itpub.net All Right Reserved. 北京盛拓优讯信息技术有限公司版权所有 联系我们 
京ICP备09055130号-4  北京市公安局海淀分局网监中心备案编号:11010802021510 广播电视节目制作经营许可证:编号(京)字第1149号
  
快速回复 返回顶部 返回列表