Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-06-13 Thread Dean Rasheed
On 13 June 2013 01:11, Tom Lane wrote: > Dean Rasheed writes: >> The more I read the spec, the less sense it seems to make, and each >> time I read it, I seem to reach a different conclusion. > >> On my latest reading, I've almost convinced myself that "updatable" is >> meant to imply support for

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-06-12 Thread Tom Lane
Dean Rasheed writes: > The more I read the spec, the less sense it seems to make, and each > time I read it, I seem to reach a different conclusion. > On my latest reading, I've almost convinced myself that "updatable" is > meant to imply support for all 3 operations (INSERT, UPDATE and > DELETE)

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-06-12 Thread Dean Rasheed
On 12 June 2013 18:35, Tom Lane wrote: > looking at this patch some more ... > > Dean Rasheed writes: >> One place where I think we have diverged from the spec, however, is in >> information_schema.columns.updatable. This should be returning 'YES' >> if the individual column is updatable, and I s

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-06-12 Thread Tom Lane
looking at this patch some more ... Dean Rasheed writes: > One place where I think we have diverged from the spec, however, is in > information_schema.columns.updatable. This should be returning 'YES' > if the individual column is updatable, and I see no reason for that > the require the relation

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-05-20 Thread Dean Rasheed
On 16 May 2013 22:16, Tom Lane wrote: >> Specifically, for foreign tables >> information_schema.tables.is_insertable_into and >> information_schema.columns.is_updatable always say 'NO' even if the >> foreign table is writable. Fixing that would require new C functions >> along the same lines as pg

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-05-16 Thread Dean Rasheed
On 16 May 2013 22:16, Tom Lane wrote: > This is assuming that an FDW that defines, say, ExecForeignDelete > is thereby promising that *all* tables it supports are deletable. That > is not required by the current FDW API spec. > Ah OK, I didn't appreciate that distinction. > If we want to do som

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-05-16 Thread Andrew Dunstan
On 05/16/2013 05:16 PM, Tom Lane wrote: Dean Rasheed writes: I've just started 9.3 beta testing and I noticed that a "simple" view defined on top of a writable foreign table is not automatically updatable. Given that these are both new-to-9.3 features, I think it would be a shame if they don't

Re: [HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-05-16 Thread Tom Lane
Dean Rasheed writes: > I've just started 9.3 beta testing and I noticed that a "simple" view > defined on top of a writable foreign table is not automatically > updatable. > Given that these are both new-to-9.3 features, I think it would be a > shame if they don't work together. It's basically a

[HACKERS] [9.3] Automatically updatable views vs writable foreign tables

2013-05-16 Thread Dean Rasheed
Hi, I've just started 9.3 beta testing and I noticed that a "simple" view defined on top of a writable foreign table is not automatically updatable. Given that these are both new-to-9.3 features, I think it would be a shame if they don't work together. It's basically a 1-line patch to make such v