Re: Delete large amount of records and INSERT (with indexes) goes VERY slow
От | Alvaro Herrera |
---|---|
Тема | Re: Delete large amount of records and INSERT (with indexes) goes VERY slow |
Дата | |
Msg-id | 20030409170705.GB3551@dcc.uchile.cl обсуждение исходный текст |
Ответ на | Re: Delete large amount of records and INSERT (with indexes) goes VERY slow (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: Delete large amount of records and INSERT (with indexes) goes VERY slow
Re: Delete large amount of records and INSERT (with indexes) |
Список | pgsql-general |
On Wed, Apr 09, 2003 at 12:59:01PM -0400, Tom Lane wrote: > Peter Nixon <listuser@peternixon.net> writes: > > > I then reran my import script and found that I was getting approximately 1 > > INSERT every 30 secconds!!! although SELECTS were working relatively > > quickly. > > I think your mistake was to do VACUUM ANALYZE while the table was empty. > That led the planner to generate plans suitable for a very small table > --- seqscans instead of indexscans, for example. But he _is_ getting good performance for SELECT, so the plans are not that bad. Only insertion is slow. Can this be related to the btree index bloating issue you fixed on january? > A byproduct of rebuilding the index was to update the planner's idea > of how big the table is, at which point the plans went back to normal. But the index was recreated from scratch and thus free of any bloating. -- Alvaro Herrera (<alvherre[a]dcc.uchile.cl>) "Hay que recordar que la existencia en el cosmos, y particularmente la elaboración de civilizaciones dentre de él no son, por desgracia, nada idílicas" (Ijon Tichy)
В списке pgsql-general по дате отправления: