Re: [HACKERS] psql nested queries with 2000+ records
| От | Coronach |
|---|---|
| Тема | Re: [HACKERS] psql nested queries with 2000+ records |
| Дата | |
| Msg-id | 3.0.5.32.19980321011207.007eb100@diety.conclave.org обсуждение исходный текст |
| Ответ на | Re: [HACKERS] psql nested queries with 2000+ records (Bruce Momjian <maillist@candle.pha.pa.us>) |
| Ответы |
Re: [HACKERS] psql nested queries with 2000+ records
|
| Список | pgsql-hackers |
>select * into games2 from games;
amusements=> select * into games2 from games;
ERROR: parser: parse error at or near "games2"
But, I just dumped it and changed a few things to fit the scenario...
>explain select name from games where name in (select name from games2 where
>name like 'A%');
amusements=> explain select name from games where name in (select name from
game
s2 where name like 'A%');
NOTICE: QUERY PLAN:
Seq Scan on games (cost=207.95 size=446 width=12)
SubPlan
-> Seq Scan on games2 (cost=10.23 size=1 width=12)
EXPLAIN
Upon execution of the query, it still took quite a long time.
>causing the problem. I assume you have run vacuum and vacuum analyze.
Yep, ran vacuum on it and also had it work with newly generated databases too.
Any other suggestions would be welcome, thanks
-Coronach@hill-b-073.resnet.purdue.edu
В списке pgsql-hackers по дате отправления: