Quote:
|
Originally Posted by chandra131
Can i improve performance by
2. changing WHERE clause field sequence, based on index key field sequence ? will it improve performance ?
|
No, definitely not. The order of WHERE predicates does not influence the optimizer's decisions.
Quote:
|
Originally Posted by chandra131
Can i improve performance by
1. create another index ?
|
Of course.
E.g., an index on (DRMT_DET_PAR_NBR, DRMT_SYS_ID, DRMT_DET_PAR_DTE, DRMT_DR_CR_IND, DRMT_DIST_SETT_DTE, DRMT_DET_AMT) would help both queries.
Also an index on (DRMT_DET_PAR_NBR, DRMT_SYS_ID, DRMT_DET_PAR_DTE, DRMT_DR_CR_IND, DRMT_DET_AMT, DRMT_ACH_TRAN_CD, DRMT_DIST_ACCT_NBR, DRMT_ORIG_ACCT_NBR) could help, since its use would make the query use just index-only access.
Finally, adding column DRMT_DIST_SETT_DTE to that last index would be useful for both purposes, so it would "certainly" be picked by the optimizer.
On the other hand, I don't expect creating any of these three indexes would be a good idea since "best overall performance" is more complex than just "tune the system for this particular query only".