Re: CREATE MATERIALIZED VIEW .. FOR UPDATE

From: Kevin Grittner <kgrittn(at)ymail(dot)com>
To: Kevin Grittner <kgrittn(at)ymail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: CREATE MATERIALIZED VIEW .. FOR UPDATE
Date: 2013-08-14 14:51:28
Message-ID: 1376491888.48883.YahooMailNeo@web162905.mail.bf1.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Kevin Grittner <kgrittn(at)ymail(dot)com> wrote:
> Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
>
>> Does the combination in $SUBJECT make sense?
>
> I don't think so; I don't know what it would mean.

Oh, I see -- it's part of the SELECT statement, causing a row-level
lock on each row as it is accessed.

>> It is currently allowed,
>
> I will take a look.

Now that I'm reading it correctly, it seems within the realm of
possibility that someone might have a legitimate use for this.  I
don't see any reason to jump through any hoops to prevent anyone
from doing it.  It is worth noting that both CREATE VIEW and CREATE
TABLE AS allow the same thing.

Thanks for pointing this out, though.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim Nasby 2013-08-14 18:23:06 Re: StrategyGetBuffer optimization, take 2
Previous Message Merlin Moncure 2013-08-14 13:30:45 Re: StrategyGetBuffer optimization, take 2