What are "versions" of an SQL statement?
来源:互联网 发布:数组的长度是什么 编辑:程序博客网 时间:2024/05/21 09:20
refer: http://www.ixora.com.au/q+a/0010/27021816.htm
From:Steve AdamsDate:27-Oct-2000 03:18Subject: What are "versions" of an SQL statement?
I'm sure that I've answered this question before, but I cannot find the answer at the moment, so here it is again. Let us say that I want to parse the statement:
select sum(discount) from sales where region = :1Oracle will compute the hash value for this SQL statement and search the hash chain for that hash value via the library cache hash table looking for an existing cached SQL statement with exactly the same text. Before an execution plan for this statement prepared for another session can be shared however, Oracle has to check several things.
It has to make sure that this session is referring to the same database objects as the previous session - not objects of the same name in a different schema. The initialization parameters that influence the optimizer must match. The NLS environments must match. And finally, the types and lengths of bind variables must match.
If any of these checks fails, then Oracle regards it as a new version of the same statement and prepares a new execution plan. The existing version (or versions) are not discarded from the library cache, because it (they) might yet be reused by other sessions.
What do you mean by "many versions of a sharable SQL statement in the SQL AREA"?
- What are "versions" of an SQL statement?
- What are the benefits of PreparedStatement over Statement
- What are the different versions of JSF and when was it released?
- SQL Error:An aggregate may not appear in the set list of an UPDATE statement.
- Frequence statement of SQL
- what kind of project are people doing?
- What are the Types of Inforecords
- 10010---What are some of your strenths
- 10011---What are some of your weaknesses
- What Kind of Friends Are You?
- What Kind of Friends Are You?
- What Kind of Friends Are You?
- ZOJ3960-What Kind of Friends Are You?
- What Kind of Friends Are You?
- What are the differences between HDMI versions 1.1, 1.2, 1.3a, 1.4a and 2.0?
- Found 2 versions of android-support-v4.jar in the dependency list,but not all the versions are ident
- what are the semantics of a const member function
- What are the different kinds of parsers used in XML?
- 序列点
- java学习札记(18)-static import
- (转)MyEclipse详解及MyEclipse7.5的优化
- 回发或回调参数无效。在配置中使用 或在页面中使用 启用了事件验证。
- javascript 函数讲
- What are "versions" of an SQL statement?
- (转)浅谈MyEclipse内存不足(JVM内存)
- POJ --北大ACM题分类
- Parent and child cursors in the library cache
- 关键代码段 Critical Section
- final特性
- 图片重定位后,不能显示。问题_1
- 启动盘是什么
- 文献搜索方法概述