Search Postgresql Archives

Re: Select max(primary_key) taking a long time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Merlin Moncure writes:

do a big delete recently?  any other open transactions?

Some inserts were taking place. Roughly 2 to 5 million rows inside transactions. We were doing some ETL and each batch represented a file we were loading. We need to have the entire file or roll back so each file is done within a transaction.

the remedy for the former is to simply eat it (one time penalty) or
rebuild the table.  for the latter you simply have to resolve the
other transaction.

I think it is related to the inserts... after they were done everything was back to normal.
how big is your table according to pg_relation_size()?

\dt+ is easier. :-)
116GB

--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux