Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Optimize SELECE SQL Query
On Apr 24, 8:39 am, beerora <beersa.bee..._at_gmail.com> wrote:
> Hi,
>
> Oracle client Version 9, OS WinXP, About 6 million rows, index on
> a.name.
>
> I have a following SQL query.
>
> Select a.id,a.name,a.age,a.class,a.tel from table01 a, table02 b
> where a.name=USER and (a.id=b.id01 or a.id=b.id02 or a.id=b.id03 or
> a.id=b.id04 or a.id=b.id05 or. a.id=b.id06)
>
> The above query took long time.
>
> How can I optimize this for better result?
>
> Thanks.
What indexes do you have on the id column in the a or b tables?
It looks like something is horribly wrong with the relational design of at least the b table part if not more. Received on Tue Apr 24 2007 - 19:24:24 CDT
![]() |
![]() |