Re: Query Rewrite with Postgres' materialized views

From: Eric Grinstein <ericgrinstein(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Query Rewrite with Postgres' materialized views
Date: 2015-02-21 18:27:14
Message-ID: CAK7uWEzk1CEntDstCu93T4vYh5cSydHKQMk2MY=e32wsve2ymw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thank you for your answers.
I am very eager to contribute to Postgres, especially in the materialized
views area.
I have created a thread
<http://www.postgresql.org/message-id/CAK7uWEzzXJjsXP9UoXWHpnjjutjaJVpkja9SkZaLsNNrDJsJ6A@mail.gmail.com>
proposing
to work on it as my Google Summer of Code project.
It became a consensus that implementing the query rewrite feature would be
unfeasible
for such a short period of time, but Tomas Vondra suggested I could work on
a first part of It, such as
making a staleness flag for the MVs. If you have any opinions on the
thread, i'd be pleased to read them.

Thank you and regards,

Eric

2015-02-21 16:09 GMT-02:00 Robert Haas <robertmhaas(at)gmail(dot)com>:

> On Sat, Feb 21, 2015 at 1:04 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> > Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> >> I'm not really sure what Josh was talking about in that answer. In
> >> terms of doing this automatically, I doubt that's likely to happen
> >> until we have a way to automatically update a materialized view when
> >> the underlying data changes --- and Kevin Grittner has done a bunch of
> >> work towards that, but more is needed to get us there.
> >
> > Even with auto maintenance, it seems unlikely that matviews would ever
> > be so transparent that it would be okay for the planner to automatically
> > substitute them into a query. The data in a matview is going to be at
> > least a little bit stale, else You're Doing It Wrong.
>
> Perhaps, but this is a feature we've gotten MANY customer requests
> for. IDK why, but it's true.
>
> --
> Robert Haas
> EnterpriseDB: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2015-02-21 18:34:51 Re: Query Rewrite with Postgres' materialized views
Previous Message Andrew Dunstan 2015-02-21 18:20:04 Re: Bootstrap DATA is a pita