It's real a quite big question and I'm trying to answer it in short.
[url=http://www.oraclepoint.com]VeRaIw4qVOraclePointA94DNrAWw[/url]
Basically, when we talk about tuning long running query, I'll follow two ways below.
- Explain Plan (see AskTome posting here) If I were you, I'll keep my eyes on any unreasonable Full Table Scan, or extreme high cost)
- Generate Statspack report (see OraclePoint post here for detail) You may need to pay attention to Hit Ratio and Top Five Wait Event. Some sql statement tuning is eventually caused by system resource limitation, not code writting of sql statement.
If you have oracle metalink account, why don't you read the articles listed at
this posting.
[url=http://www.oraclepoint.com]I3QUXgrqmOraclePointfjnl5H4VQ[/url]
Hope it helps.