Re: ON CONFLICT DO UPDATE for partitioned tables - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: ON CONFLICT DO UPDATE for partitioned tables
Date
Msg-id 20180416191003.34xjvru45icn53ko@alvherre.pgsql
Whole thread Raw
In response to Re: ON CONFLICT DO UPDATE for partitioned tables  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Responses Re: ON CONFLICT DO UPDATE for partitioned tables  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: ON CONFLICT DO UPDATE for partitioned tables  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
List pgsql-hackers
Amit Langote wrote:

> The solution I came up with is to call map_variable_attnos() directly,
> instead of going through map_partition_varattnos() every time, after first
> creating the attribute map ourselves.

Yeah, sounds good.  I added a tweak: if the tupledescs are equal, there
should be no need to do any mapping.

(Minor adjustment to the test: "cuarenta" means forty, so I changed the
new test to say "cincuenta" instead, which means fifty).

Pushed now, thanks.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


pgsql-hackers by date:

Previous
From: David Arnold
Date:
Subject: Re: Proposal: Adding json logging
Next
From: Tom Lane
Date:
Subject: Re: ON CONFLICT DO UPDATE for partitioned tables