Re: pgsql: Get rid of copy_partition_key

2017-12-27 Thread Alvaro Herrera
Pushed, thanks. -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Re: pgsql: Get rid of copy_partition_key

2017-12-22 Thread Alvaro Herrera
Seems I misremembered the whole opfuncid getting reset thing (it applies to reading a node from string, not copying) and it was undone by 9f1255ac8593 anyway. I don't think it makes much of a difference, but I mention this in case you're wondering why I changed the fix_opfuncids() call. -- Álvar

Re: pgsql: Get rid of copy_partition_key

2017-12-22 Thread Alvaro Herrera
I believe this patch (which also fixes a comment I neglected to fix in the previous one) should satisfy your concerns. It's still running a few relevant tests (create_function_1 create_type point polygon circle create_table copy create_misc create_index alter_table partition_join partition_prune h

Re: pgsql: Get rid of copy_partition_key

2017-12-21 Thread Alvaro Herrera
Robert Haas wrote: > On Thu, Dec 21, 2017 at 12:43 PM, Alvaro Herrera > wrote: > > Get rid of copy_partition_key > > > > That function currently exists to avoid leaking memory in > > CacheMemoryContext in case of trouble while the partition key is being > > built, but there's a better way: allocat

Re: pgsql: Get rid of copy_partition_key

2017-12-21 Thread Robert Haas
On Thu, Dec 21, 2017 at 12:43 PM, Alvaro Herrera wrote: > Get rid of copy_partition_key > > That function currently exists to avoid leaking memory in > CacheMemoryContext in case of trouble while the partition key is being > built, but there's a better way: allocate everything in a memcxt that > g