I had an doubt in Performance Tuning.
See we use autotrace on/execution plan for finding the query performance.
In that we get the output as
NESTED JOINS or SORT_MERGE JOIN or HASH JOIN.
oracle document says
NESTED JOIN is best for the queries returns >= 10000 rows.
SORT_MERGE JOIN is best if we use CBO.
HASH_JOIN is best if we use RBO.
We are using oracle 9i. in that the default optimizer is CBO.
So how come we know that which join is best and how to tune the query?
Please Clarify this........
Thanks in Advance....
The best thing you could do is avoid rules of thumb like this.
Start by read the Oracle documentation and understanding the fundamental differences between each join type -- there is no one that is universally better than others.
Oh, here's the only rule of thumb -- analyze your tables, indexes, and skewed columns.
Click Here to Expand Forum to Full Width