On 11/26/12 2:07 PM, Robert Haas wrote:
> On Sun, Nov 25, 2012 at 7:30 PM, Marko Tiikkaja <pgmail@joh.to> wrote:
>> As others have pointed out, replacing the contents of a table is something
>> which people have been wanting to do for a long time, and I think having
>> this ability would make this patch a lot better; now it just feels like
>> syntactic sugar.
>
> I agree that it's mostly syntactic sugar, but I think we need to have
> realistic expectations for what is possible in an initial patch. When
> I committed the first patch for foreign data wrappers, it didn't work
> at all: it was just syntax support. Tom later committed a follow-on
> patch that made them work. Similarly, I split the event trigger patch
> into two halves, one of which added the syntax support and the other
> of which made them functional: and even with both commits in, I think
> it's fair to say that event triggers are still in a fairly primitive
> state.
>
> None of those patches were small patches. It's going to take multiple
> years to get materialized views up to a state where they're really
> useful to a broad audience in production applications, but I don't
> think we should sneer at anyone for writing a patch that is "just
> syntactic sugar". As it turns out, adding a whole new object type is
> a lot of work and generates a big patch even if it doesn't do much
> just yet. Rejecting such patches on the grounds that they aren't
> comprehensive enough is, IMHO, extremely unwise; we'll either end up
> landing even larger patches that are almost impossible to review
> comprehensively and therefore more likely to break something, or else
> we'll kill the projects outright and end up with nothing.
First of all, I have to apologize. Re-reading the email I sent out last
night, it does indeed feel a bit harsh and I can understand your reaction.
At no point did I mean to belittle Kevin's efforts or the patch itself. I was mostly looking for Kevin's input on how
hardit would be to
solve the particular problem and whether it would be possible to do so
for 9.3.
While I feel like the problem I pointed out is a small caveat and should
be at least documented for 9.3, I think this patch has merits of its own
even if that problem never gets fixed, and I will continue to review
this patch.
Regards,
Marko Tiikkaja