Re: How to avoid "Seq Scans"?
От | A. Kretschmer |
---|---|
Тема | Re: How to avoid "Seq Scans"? |
Дата | |
Msg-id | 20070829092921.GB7841@a-kretschmer.de обсуждение исходный текст |
Ответ на | How to avoid "Seq Scans"? (Vincenzo Romano <vincenzo.romano@gmail.com>) |
Список | pgsql-general |
am Wed, dem 29.08.2007, um 11:15:21 +0200 mailte Vincenzo Romano folgendes: > This loop is increadibly slow. Infact the friendly explain tells me > that: > > test=# explain select * from t order by f2,f3; > QUERY PLAN > --------------------------------------------------------------------------------- > Sort (cost=958786.20..970734.55 rows=4779338 width=28) > Sort Key: f2,f3 > -> Seq Scan on t (cost=0.00..85501.38 rows=4779338 width=28) > > I'd like to know a hint about a technicque to avoid the sequential > scan! A 'select foo from bar' without a WHERE-condition forces a seq-scan because _YOU_ want the whole table. Andreas -- Andreas Kretschmer Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header) GnuPG-ID: 0x3FFF606C, privat 0x7F4584DA http://wwwkeys.de.pgp.net
В списке pgsql-general по дате отправления: