Wednesday, 18 November 2009

New Features for Administrators - Question 004

Oracle9i extends the cursor sharing functionality with the new value of SIMILAR for the CURSOR_SHARING parameter. With CURSOR_SHARING = SIMILAR, cursors are shared for safe literals only. What is meant by 'safe literals only'?

A. No literal value is substituted for a shared cursor.

B. Different execution plans are generated for substituted literal values.

C. The substitution of a literal value will produce different execution plans.

D. The substitution of any literal value will produce exactly the same execution plan.

Answer: D

Explanation:

Oracle9i has enhanced cursor sharing mode. It can use additional value, SIMILAR, in addition to the EXACT and FORCE cursor sharing modes. When you specify SIMILAR, Oracle only uses the execution plan if is certain that the execution plan does not have any association with the specific literal value. You can enable similar statements to share the same SQL execution plan by setting CURSOR_SHARING to either FORCE or SIMILAR.

Incorrect Answers

- 7 -

A: A Literal value is substituted for a shared cursor. The substitution of any literal value will produce exactly the same execution plan.

B: Exactly the same execution plans will be generated for substituted literal values.

C: The substitution of any literal value will produce exactly the same execution plan.

OCP Oracle9i Database: New Features for Administrators, Daniel Benjamin, p. 215-217

Chapter 4: Performance and Scalability Enhancements

Oracle 9i New Features, Robert Freeman, p. 57-59

Chapter 2: Oracle9i Architecture Changes

No comments:

Post a Comment