Re: INSERT to partitioned table doesn't return row count - Mailing list pgsql-general

From David G Johnston
Subject Re: INSERT to partitioned table doesn't return row count
Date
Msg-id 1417642288104-5829163.post@n5.nabble.com
Whole thread Raw
In response to Re: INSERT to partitioned table doesn't return row count  (Kris Deugau <kdeugau@vianet.ca>)
List pgsql-general
Kris Deugau wrote
> David G Johnston wrote:
>> Going from recent memory this particular behavior complaint has now come
>> up
>> three times in the past six months - the main complaint previously is
>> that
>> given an insert trigger for the partition you have to copy, not move, the
>> insert to the child tables - leaving the parent table populated during
>> the
>> insert and thus returning the count - and then delete the record from the
>> parent table.  That sequence, while solving the row number problem, then
>> causes vacuum to behave undesirably.
>
> Eugh.  For the (mostly) one-off bulk-copy process I've been preparing I
> have a couple of other workarounds (simplest being just inserting in the
> child table directly), but if it comes down to it it will be simpler to
> put up with the relatively minor nuisance of staying unpartitioned
> rather than (potentially) destabilizing someone else's code.  After all,
> I've already written the code to archive old records from the
> unpartitioned table anyway...  it just would have been nice to be able
> to "pg_dump dbname -t table_2013" instead.

The specific thread I was thinking of is here:

http://postgresql.nabble.com/Autovacuum-on-partitioned-tables-in-version-9-1-td5826595.html

The links referenced there provide the basis for my thought that there might
be 3 recent examples...

David J.




--
View this message in context:
http://postgresql.nabble.com/INSERT-to-partitioned-table-doesn-t-return-row-count-tp5829148p5829163.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


pgsql-general by date:

Previous
From: Kris Deugau
Date:
Subject: Re: INSERT to partitioned table doesn't return row count
Next
From: Adrian Klaver
Date:
Subject: Re: Postgres 9.2 PITR testing to before DROP DATABASE ends up removing file system files