Les01 RW
Les01 RW
Les01 RW
Check
Archiver
point Control Redo log ARC0
CKPT Data
file files
files
Control files
SGA
SGA
User Server
Oracle database
User Server
Client
User Server
Browser
Open Close
• Parse phase:
– Searches for the statement in the shared pool
– Checks syntax
– Checks semantics and privileges
– Merges view definitions and subqueries
– Determines execution plan
• Minimize parsing as much as possible:
– Parse calls are expensive
– Avoid reparsing
– Parse once, execute many times
• Bind phase:
– Checks the statement for bind variables
– Assigns or reassigns a value to the bind variable
• Bind variables impact performance when:
– They are not used, and your statement would
benefit from a shared cursor
– They are used, and your statement would benefit
from a different execution plan
• Execute phase:
– Executes the SQL statement
– Performs necessary I/O and sorts for data
manipulation language (DML) statements
• Fetch phase:
– Retrieves rows for a query
– Sorts for queries when needed
– Uses an array fetch mechanism
Database SGA
2 Database
buffer cache
1
Data Redo log
Server 3 buffer
files process
Shared pool
UPDATE
Control employees ...
files
4
User
Redo process
log files
Control
files
User
process
Redo
log files LGWR