Hi i am in the learning phase of query tuning, I have this query executed in our prod, which does more sorting.. Just want to understand how this can be tuned to give better performance.
SELECT SUM(consumption), SUM(demand), MIN(start_dts_lt), MAX(end_dts_lt), MIN(start_dts_z), MAX(end_dts_z) FROM GEMS.METER_CON
S_SUM_1H WHERE ruletimestamp= '2012-01-11 06:31:02.674050' AND HOUR(start_dts_lt)=17 AND DATE(start_dts_lt)='2012-01-10' AND o
rgname='WPL' AND location='EC4' AND meterid IN (SELECT assetuid FROM GEMS.MAXIMO_ASSETMETER_SVC_CONS_SUM_DAY WHERE parentuid L
IKE 'C_WPLxL_EC4xMA_OFA02xEC_11' AND type='CALCULATED')
there are many such query i want to have a basic understanding hw to approach on these kind of query.
pl. suggest any free tools for the same.