Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Index not used when select contain *
I've this problem:
i've create an index with 4 field
CREATE UNIQUE INDEX AOS_INDEX_LNK23_X_LAS ON LNK23_RICHIESTA_SIS_EST
(L23_STATO, L23_DATAORA_RICH, L23_NUM_RICHIESTA, L23_NUM_EPISODIO)
The table contain 20 field and the primary key is:
PRIMARY KEY (L23_DATAORA_RICH, L23_NUM_RICHIESTA, L23_NUM_EPISODIO)
with this: query:
SELECT L23_STATO, L23_DATAORA_RICH, L23_NUM_RICHIESTA, L23_NUM_EPISODIO
FROM GSTUSER.LNK23_RICHIESTA_SIS_EST
WHERE L23_STATO='C'
the index is used
but with this
SELECT *
FROM GSTUSER.LNK23_RICHIESTA_SIS_EST
WHERE L23_STATO='C'
the index in not ued.
Please, can you tell me where is the problem?
Received on Mon Sep 11 2006 - 03:46:16 CDT
![]() |
![]() |