performance of a self join on oracle db -


i have self join slow on oracle db. have put indexes on fields concerned. have advice on how increase performance?

select count(tnew.idtariffa)  cont       tariffe tatt      join tariffe tnew on tatt.idtariffa = tnew.idtariffa      (tatt.stato_attivo = 't')       , (tnew.stato_attivo = 'f')       , (tatt.validity_date < tnew.validity_date)       , (tatt.dataimport < tnew.dataimport)       , (tnew.validity_date < to_date('2017-6-26','yyyy-mm-dd')) 

try push_pred hint :

select /*+ no_merge(tnew) push_pred(tnew) */ count(tnew.idtariffa)  cont       tariffe tatt      join tariffe tnew on tatt.idtariffa = tnew.idtariffa      (tatt.stato_attivo = 't')       , (tnew.stato_attivo = 'f')       , (tatt.validity_date < tnew.validity_date)       , (tatt.dataimport < tnew.dataimport)       , (tnew.validity_date < to_date('2017-6-26','yyyy-mm-dd')) 

Comments

Popular posts from this blog

python - Selenium remoteWebDriver (& SauceLabs) Firefox moseMoveTo action exception -

html - How to custom Bootstrap grid height? -

transpose - Maple isnt executing function but prints function term -