Quote:
|
Originally Posted by ankur02018
how can we choose that on which column is to make index to make search more efficient
|
DB2 (unlike some other databases) has an excellent optimizer, and should chose the correct index so long as it has accurate statistics (from a runstats command). If you don't think that DB2 is chosing the correct index, then open a problem with IBM support.
If DB2 choses the wrong access path because the number of rows in the table varies drastically within a short timespan, alter the table and set it to volatile.