Home » RDBMS Server » Performance Tuning » when use_hash related hint is used?
when use_hash related hint is used? [message #222516] Mon, 05 March 2007 04:57 Go to next message
p.bhaskar
Messages: 33
Registered: February 2007
Location: kolkata
Member
my query is ---------->




select
a.emp_id,a.emp_first_name||' '||a.emp_mid_name||' '||a.emp_last_name emp_name,
c.emp_code,
d.attd_point_code,
b.emp_category_code category,
c.emp_category_id,
c.shift ,
c.attd_point_id ,
rowidtochar(a.rowid) ROW_ID
from
m_pis_employee a,
m_pis_emp_category b ,
t_pis_emp_shift c,
m_pis_dept_attd_point d
where
a.emp_code = c.emp_code
and c.emp_category_id=b.emp_category_id
--and a.emp_code = c.emp_code
and d.attd_point_id=c.attd_point_id
and c.pre_posting_loc_id in(select pre_posting_loc_id from t_pis_emp_shift where emp_code='01340348'
and week_start_date <= '06-JAN-2007' and week_end_date >='06-JAN-2007')
and c.attd_point_id in(select attd_point_id from t_pis_emp_shift where emp_code='01340348'
and week_start_date <= '06-JAN-2007' and week_end_date >='06-JAN-2007')
and c.shift in (select shift from t_pis_emp_shift where emp_code='01340348'
and week_start_date <= '06-JAN-2007' and week_end_date >='06-JAN-2007')
and c.week_start_date <= '06-JAN-2007' and c.week_end_date >='06-JAN-2007'
and c.emp_code>='01340348' order by c.emp_code


explain plan is uploaded----

[Updated on: Mon, 05 March 2007 06:24]

Report message to a moderator

Re: when use_hash related hint is used? [message #222534 is a reply to message #222516] Mon, 05 March 2007 05:37 Go to previous message
Mahesh Rajendran
Messages: 10708
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
You need to explain what you mean by purely optimized.
Hint is just a hint.
The actuall work done is based on statistics on table and generated join stats. Post more details!
Previous Topic: Tuning of a sql querry
Next Topic: Nested loops, Hash join and Sort Merge joins – difference?
Goto Forum:
  


Current Time: Wed Nov 27 01:30:23 CST 2024