>   create table stuff(a,b,c,d);
>   insert into stuff values(1,2,3,4);
>   create temp view v1 as select random()%100,
>     random()%100, random()%1000, random()%10000
>      from stuff x, stuff y;
>   insert into stuff select * from v1;
>   insert into stuff select * from v1;
>   insert into stuff select * from v1;
>   insert into stuff select * from v1;
>   insert into stuff select * from v1;
>   create index stuff_b on stuff(b);
>   create index stuff_c on stuff(c);
>   create index stuff_d on stuff(d);
>   analyze;

A better example of this issue would be:

  -- 47 seconds
  select c from stuff where a=23 group by c;

vs.

  -- 2 seconds
  select c from stuff where a=23 group by +c;

since there is no index on a.




      
____________________________________________________________________________________
Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to