Re: Materialized views WIP patch

From: Craig Ringer <craig(at)2ndquadrant(dot)com>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: Materialized views WIP patch
Date: 2013-03-04 04:04:07
Message-ID: 51341D37.5020506@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On 03/04/2013 08:27 AM, Josh Berkus wrote:
>> There's a much more fundamental reason why this will never happen, which
>> is that the query planner is not licensed to decide that you only want
>> an approximate and not an exact answer to your query.
> I think it would be worth talking about when someone wants to implement
> it. I'd imagine it would require setting a GUC, though, which would be
> off by default for obvious reasosn.
I'm not a fan of this, even with a GUC. Imagine doing remote debugging
by email/phone. There are enough things to check already ("does your
application REALLY commit that transaction?") without also having to
deal with settings that can cause a potentially out of date view of the
data to be used without it being visible in the query its self.

I hate to even say it, but this is where a per-query [redacted] would be
good, so we could say in the query text that this query may use matviews
that are not perfectly up to date.

At this point it's all hand-waving anyway, since no feature to allow the
planner to automatically rewrite a subtree of a query to use a matview
instead exists.

--
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Euler Taveira 2013-03-04 13:37:32 Re: Materialized views WIP patch
Previous Message Peter Eisentraut 2013-03-04 03:23:15 pgsql: psql: Let \l accept a pattern

Browse pgsql-hackers by date

  From Date Subject
Next Message Craig Ringer 2013-03-04 04:11:20 Re: Re: Proposal for Allow postgresql.conf values to be changed via SQL [review]
Previous Message Craig Ringer 2013-03-04 03:58:25 Re: Partial patch status update, 3/3/13