Re: Update does not move row across foreign partitions in v11

2019-03-12 Thread Amit Langote
On 2019/03/13 1:04, Alvaro Herrera wrote: > On 2019-Mar-09, Amit Langote wrote: > >> Attached find 3 patches -- for PG 10, 11, and HEAD. I also realizes >> that a description of PARTITION OF clause was also missing in the >> Parameters section of CREATE FOREIGN TABLE, which is fixed too. > > Tha

Re: Update does not move row across foreign partitions in v11

2019-03-12 Thread Derek Hans
As the original reporter, thanks a ton for all the hard work you're putting into the documentation! On Tue, Mar 12, 2019, 12:04 PM Alvaro Herrera wrote: > On 2019-Mar-09, Amit Langote wrote: > > > Attached find 3 patches -- for PG 10, 11, and HEAD. I also realizes > > that a description of PART

Re: Update does not move row across foreign partitions in v11

2019-03-12 Thread Alvaro Herrera
On 2019-Mar-09, Amit Langote wrote: > Attached find 3 patches -- for PG 10, 11, and HEAD. I also realizes > that a description of PARTITION OF clause was also missing in the > Parameters section of CREATE FOREIGN TABLE, which is fixed too. Thanks! Applied all three -- I appreciate your help in

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Amit Langote
On Sat, Mar 9, 2019 at 12:03 AM Alvaro Herrera wrote: > > On 2019-Mar-08, Amit Langote wrote: > > > On Fri, Mar 8, 2019 at 11:09 PM Alvaro Herrera > > wrote: > > > > I'm not sure about copying the same to ddl.sgml. Why is that needed? > > > Update is not DDL. > > > > Hmm, maybe because there's

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Alvaro Herrera
On 2019-Mar-08, Amit Langote wrote: > On Fri, Mar 8, 2019 at 11:09 PM Alvaro Herrera > wrote: > > I'm not sure about copying the same to ddl.sgml. Why is that needed? > > Update is not DDL. > > Hmm, maybe because there's already a huge block of text describing > certain limitations of UPDATE

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Amit Langote
On Fri, Mar 8, 2019 at 11:09 PM Alvaro Herrera wrote: > > On 2019-Mar-08, Amit Langote wrote: > > > diff --git a/doc/src/sgml/ref/update.sgml b/doc/src/sgml/ref/update.sgml > > index 77430a586c..f5cf8eab85 100644 > > --- a/doc/src/sgml/ref/update.sgml > > +++ b/doc/src/sgml/ref/update.sgml > > @@

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Alvaro Herrera
On 2019-Mar-08, Amit Langote wrote: > diff --git a/doc/src/sgml/ref/update.sgml b/doc/src/sgml/ref/update.sgml > index 77430a586c..f5cf8eab85 100644 > --- a/doc/src/sgml/ref/update.sgml > +++ b/doc/src/sgml/ref/update.sgml > @@ -291,9 +291,9 @@ UPDATE count > concurrent UPDATE or DELETE on the

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Amit Langote
On Fri, Mar 8, 2019 at 8:21 PM David Rowley wrote: > > On Sat, 9 Mar 2019 at 00:09, Etsuro Fujita > wrote: > > IMO I think it's better that we also mention that the UPDATE can move > > rows into a foreign partition if the FDW supports it. No? > > In my opinion, there's not much need to talk abo

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread David Rowley
On Sat, 9 Mar 2019 at 00:09, Etsuro Fujita wrote: > IMO I think it's better that we also mention that the UPDATE can move > rows into a foreign partition if the FDW supports it. No? In my opinion, there's not much need to talk about what the limitations are not when you're mentioning what the li

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread Etsuro Fujita
(2019/03/08 19:29), David Rowley wrote: On Fri, 8 Mar 2019 at 15:07, Amit Langote wrote: David, can you confirm if the rewritten text reads unambiguous or perhaps suggest a better wording? So this is the text: + Currently, rows cannot be moved from a foreign-table partition to some +

Re: Update does not move row across foreign partitions in v11

2019-03-08 Thread David Rowley
On Fri, 8 Mar 2019 at 15:07, Amit Langote wrote: > David, can you confirm if the rewritten text reads unambiguous or perhaps > suggest a better wording? So this is the text: + Currently, rows cannot be moved from a foreign-table partition to some + other partition, but they can be mo

Re: Update does not move row across foreign partitions in v11

2019-03-07 Thread Amit Langote
Thanks for the review. On 2019/03/07 21:35, Etsuro Fujita wrote: > The patch looks good to me, but one thing I'm wondering is: as suggested > by David, it would be better to rephrase this mention in the UPDATE > reference page, in a single commit: > > "Currently, rows cannot be moved from a parti

Re: Update does not move row across foreign partitions in v11

2019-03-07 Thread Amit Langote
On 2019/03/07 22:54, Robert Haas wrote: > On Thu, Mar 7, 2019 at 7:35 AM Etsuro Fujita > wrote: >> Thanks for the patch! >> >> The patch looks good to me, but one thing I'm wondering is: as suggested >> by David, it would be better to rephrase this mention in the UPDATE >> reference page, in a sin

Re: Update does not move row across foreign partitions in v11

2019-03-07 Thread Robert Haas
On Thu, Mar 7, 2019 at 7:35 AM Etsuro Fujita wrote: > Thanks for the patch! > > The patch looks good to me, but one thing I'm wondering is: as suggested > by David, it would be better to rephrase this mention in the UPDATE > reference page, in a single commit: > > "Currently, rows cannot be moved

Re: Update does not move row across foreign partitions in v11

2019-03-07 Thread Etsuro Fujita
(2019/03/06 15:34), Amit Langote wrote: On 2019/03/06 15:10, Etsuro Fujita wrote: --- a/doc/src/sgml/ddl.sgml +++ b/doc/src/sgml/ddl.sgml @@ -3376,6 +3376,13 @@ ALTER TABLE measurement ATTACH PARTITION measurement_y2008m02 + + +UPDATE row movement is not supported in the cases

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
Fujita-san, On 2019/03/06 15:10, Etsuro Fujita wrote: > --- a/doc/src/sgml/ddl.sgml > +++ b/doc/src/sgml/ddl.sgml > @@ -3376,6 +3376,13 @@ ALTER TABLE measurement ATTACH PARTITION > measurement_y2008m02 >    >   > > + > +  > +   UPDATE row movement is not supported in the

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Etsuro Fujita
(2019/03/06 13:53), Amit Langote wrote: On 2019/03/06 13:30, David Rowley wrote: I think you missed my point. If there's no special support for "tuple moving", as you say, then what help is it to tell the user "if the FDW supports tuple routing"? The answer is, it's not any help. How would

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Etsuro Fujita
(2019/03/06 13:18), Amit Langote wrote: The main problem here is indeed that the limitation is not listed under the partitioning limitations in ddl.sgml, where it's easier to notice than in the UPDATE's page. Agreed. I've updated my patch to remove the release-11.sgml changes. Thanks for th

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
On 2019/03/06 13:30, David Rowley wrote: > On Wed, 6 Mar 2019 at 17:20, Amit Langote > wrote: >> >> On 2019/03/06 12:47, David Rowley wrote: >>> It seems a bit light on detail to me. If I was a user I'd want to know >>> what exactly the FDW needed to support this. Does it need a special >>> parti

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread David Rowley
On Wed, 6 Mar 2019 at 17:20, Amit Langote wrote: > > On 2019/03/06 12:47, David Rowley wrote: > > It seems a bit light on detail to me. If I was a user I'd want to know > > what exactly the FDW needed to support this. Does it need a special > > partition move function? Looking at ExecFindPartitio

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
On 2019/03/06 12:47, David Rowley wrote: > On Wed, 6 Mar 2019 at 16:29, Etsuro Fujita > wrote: >> That means that rows can be moved from a local partition to a foreign >> partition if the FDW supports it. > > It seems a bit light on detail to me. If I was a user I'd want to know > what exactly t

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
Fujita-san, On 2019/03/06 13:04, Etsuro Fujita wrote: > (2019/03/06 11:34), Amit Langote wrote: >> Ah, indeed.  In the documentation fix patch I'd posted, I also made >> changes to release-11.sgml to link to the limitations section.  (I'm >> attaching it here for your reference.) > > I'm not sure

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Etsuro Fujita
(2019/03/06 11:34), Amit Langote wrote: Ah, indeed. In the documentation fix patch I'd posted, I also made changes to release-11.sgml to link to the limitations section. (I'm attaching it here for your reference.) I'm not sure it's a good idea to make changes to the release notes like that,

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread David Rowley
On Wed, 6 Mar 2019 at 16:29, Etsuro Fujita wrote: > > (2019/03/06 11:06), David Rowley wrote: > > I don't quite understand what a "foreign table to some other > > partition" is meant to mean. Partitions don't have foreign tables, > > they can only be one themselves. > > I think "foreign table" is

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Etsuro Fujita
(2019/03/06 11:06), David Rowley wrote: On Tue, 5 Mar 2019 at 03:01, Derek Hans wrote: Based on a reply to reporting this as a bug, moving rows out of foreign partitions is not yet implemented so this is behaving as expected. There's a mention of this limitation in the Notes section of the Up

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
On 2019/03/06 11:29, David Rowley wrote: > On Wed, 6 Mar 2019 at 15:26, Amit Langote > wrote: >> >>> I've tried to put all this right again in the attached. However, I was >>> a bit unsure of what "but they can be moved into a foreign table if >>> the foreign data wrapper supports it." is referri

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread David Rowley
On Wed, 6 Mar 2019 at 15:26, Amit Langote wrote: > > > I've tried to put all this right again in the attached. However, I was > > a bit unsure of what "but they can be moved into a foreign table if > > the foreign data wrapper supports it." is referring to. Copying Robert > > and Etsuro as this wa

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread Amit Langote
Hi David, On 2019/03/06 11:06, David Rowley wrote: > On Tue, 5 Mar 2019 at 03:01, Derek Hans wrote: >> Based on a reply to reporting this as a bug, moving rows out of foreign >> partitions is not yet implemented so this is behaving as expected. There's a >> mention of this limitation in the Not

Re: Update does not move row across foreign partitions in v11

2019-03-05 Thread David Rowley
On Tue, 5 Mar 2019 at 03:01, Derek Hans wrote: > Based on a reply to reporting this as a bug, moving rows out of foreign > partitions is not yet implemented so this is behaving as expected. There's a > mention of this limitation in the Notes section of the Update docs. (Moving this discussion t