January 2012
Intermediate to advanced
542 pages
11h 28m
English
In this recipe we will see how not using bind variables leads to latch contentions.
We will use the same package used in Chapter 4, where we have discussed using bind variables in our application code, to compare the execution with and without the use of bind variables.
The following steps will show how we can minimize latches by using bind variables:
SYSDBA:
CONNECT / AS SYSDBA
V$SYSTEM_EVENT dynamic performance view to monitor latch-related events:COL EVENT FOR A37 SELECT EVENT, TOTAL_WAITS, TIME_WAITED, AVERAGE_WAIT, TOTAL_TIMEOUTS FROM V$SYSTEM_EVENT WHERE EVENT LIKE 'latch:%' ORDER BY EVENT;
SH schema and create the package ...Read now
Unlock full access