Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Index

Former Member
0 Likes
724

^Hello ,

I created Secondary index for a table, how do i know it is being used for my slect or not.

I have given in where condition the fields defined in index.

In ST05, i dont know i can see, when i go to DDIC explain it shows all the indexs on the table.

Where can i see which index si being used?

Rgds,

Ö

1 ACCEPTED SOLUTION
Read only

suresh_datti
Active Contributor
0 Likes
703

Hi,

In ST05, put your cursor on the Table name & click on the 'Explain' Pushbutton & then click on 'Access path'.. this should tell you which INDEX was used..

Regards,

Suresh Datti

^Hello ,

I created Secondary index for a table, how do i know it is being used for my slect or not.

I have given in where condition the fields defined in index.

In ST05, i dont know i can see, when i go to DDIC explain it shows all the indexs on the table.

Where can i see which index si being used?

Rgds,

Ö

3 REPLIES 3
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
703

You can see this in the "Explain" area of ST05. Put your cursor on the records for your table where the OP column is "OPEN". Click the "Explain" button. Now you will see the explaination of the SELECT statement. Further down the page, you will see under MAIN LEVEL 1, a tree structure, in there you will see the index which was used.

You should see something like this....

MAIN LEVEL 1                                                                                
5  SUBSELECT LEVEL 1                                                                                
5  File AFKO                                                                                
5  <b>Index R3TSTDATA/AFKO+Z01 </b>                                                                                
Reason code:                                                                                
5  Key fields of the access path used:                                                                                
MANDT                                                    
                    GLTRP                                                    
                    GETRI

Regards,

Rich Heilman

Read only

Laxmana_Appana_
Active Contributor
0 Likes
703

Hi ,

if you want to use specific index , include that index name in select like below statement. then select will work based on the specified index .

%_HINTS ORACLE 'index(index "0")'.

Laxman

Read only

suresh_datti
Active Contributor
0 Likes
704

Hi,

In ST05, put your cursor on the Table name & click on the 'Explain' Pushbutton & then click on 'Access path'.. this should tell you which INDEX was used..

Regards,

Suresh Datti