Joining Sequence

Database
Enthusiast

Joining Sequence

hi All I m using V12,
Does the sequence of joins(outer) written in the query ,have any impact on the performance of the query.
I had a query with around 60 joins ,with most of them left outer joins.
Does changing the sequence of these left outer joins can improve the performance.
or whatever is the sequence mentioned inthe queryTD will take its own course.

Thanks and Regards
Sreehari
Tags (1)
1 REPLY
Enthusiast

Re: Joining Sequence

It depends on query.
In common case - no.

It will be more effeective to collect statistics on join-fields of join tables (of course, if the are tables, and not subqueries):

collect statistics using sample on TableName column (column1 [, column2, ...]);