On Mon, 7 Jan 2008, Clodoaldo wrote:
I just did it. Built and installed 8.2.5. Copied the postgresql.conf
from the production. Issued an analyze and ran the insert query twice:
The second time it ran in 403 sec, half the production time.
OK, you're getting close now. What you should do now is run your query on
8.2.5 with EXPLAIN ANALYZE (the sample you gave before had just EXPLAIN),
run it again on that same server with 8.3, then post the two plans. Now
that it's a fair comparision looking at the differences between the two
should give an idea of the cause.
The only thing I noticed in your original explain plans that was different
between the two was:
8.2:
Merge Cond: ((ut.n_time = ui.n_time) AND
((ut.usuario)::text = "inner"."?column4?"))
8.3:
Merge Cond: ((ut.n_time = ui.n_time) AND
((ut.usuario)::text = (ui.usuario_nome)::text))
I don't read enough plans to know if that's impacting things, but seeing
the ANALYZE output that includes actual times in addition to estimated
costs will help sort out the real issue here.
--
* Greg Smith gsmith@xxxxxxxxxxxxx http://www.gregsmith.com Baltimore, MD
---------------------------(end of broadcast)---------------------------
TIP 5: don't forget to increase your free space map settings