Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: 7.3.3 Query performance problem
Ken,
ask the optimizer why it do not use the index ;-) if it doesnt answer and I think it will not answer try the following: - Change the optimizer mode from rule based to cost based or vice versa - Use optimizer hints to force the optimizer to use your index.
Marcus
Ken Walters wrote:
> This query runs quickly and the explain plan show that it is using an
> index only range scan on the VarcharColumnB. There are about 600
> records with 'E' as a value for VarcharColumnB in a table with a over
> 100K records.
>
> SELECT count(IntegerColumnA)
> FROM Table1
> WHERE VarcharColumnB = 'E';
>
> This query runs slowly and does a full table access on the table. Why?
>
> SELECT IntegerColumnA
> FROM Table1
> WHERE VarcharColumnB = 'E';
>
> Thanks in advance.
>
> --
> Ken Walters
> kwalters_at_pbs.org
> DBA
> Public Braodcasting Service
> kwalters_at_pbs.org
Received on Wed Sep 16 1998 - 13:03:09 CDT