Re: Updates on large tables are extremely slow - Mailing list pgsql-performance

From Tom Lane
Subject Re: Updates on large tables are extremely slow
Date
Msg-id 19628.1118673136@sss.pgh.pa.us
Whole thread Raw
In response to Re: Updates on large tables are extremely slow  (Yves Vindevogel <yves.vindevogel@implements.be>)
List pgsql-performance
Yves Vindevogel <yves.vindevogel@implements.be> writes:
> rvponp=3D# vacuum verbose tblPrintjobs ;
> INFO:  vacuuming "public.tblprintjobs"
> [ twenty-one different indexes on one table ]

Well, there's your problem.  You think updating all those indexes is
free?  It's *expensive*.  Heed the manual's advice: avoid creating
indexes you are not certain you need for identifiable commonly-used
queries.

(The reason delete is fast is it doesn't have to touch the indexes ...
the necessary work is left to be done by VACUUM.)

            regards, tom lane

pgsql-performance by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: Help with rewriting query
Next
From: "Kevin Grittner"
Date:
Subject: Re: Index ot being used