I think the order of column in a compound
index is very important--i.e. it should be
defined as (high_selectiviey_column, less_selectivity_column) rather than the other way around or as some people suggests
'does not matter'.... Can someone who knows
the internals of how index trees are built
shed light in this?
i.e. much better performance if index is
defined as (employee_id, department_id),
rather the other way around.