From: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com> |
---|---|
To: | marian(dot)krucina(at)gmail(dot)com |
Cc: | PostgreSQL mailing lists <pgsql-bugs(at)postgresql(dot)org> |
Subject: | Re: BUG #13907: Restore materialized view throw permission denied |
Date: | 2016-06-14 07:16:58 |
Message-ID: | CAB7nPqR-r8HMhEtEkGTr-N4kVrAJLqj-OP0wyjVin0U0BWsu5A@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On Tue, Feb 2, 2016 at 7:14 PM, <marian(dot)krucina(at)gmail(dot)com> wrote:
> restore (9.4.5, 9.5.0) or pg_upgrade (9.4.5 to 9.5.0) fail on CREATE
> MATERIALIZED VIEW.
> This is similar to:
> http://www.postgresql.org/message-id/11166.1424357659@sss.pgh.pa.us
>
> Problem is, when view runs as user definer.
> Is possible move 'CREATE MATERIALIZED VIEW' in a dump to end?
This is one of those issues where it would be cool to only plan and
execute the query creating the materialized view query with NO DATA
without planning and executing it first, and do the actual planning
and execution at the first refresh. A similar problem was discussed
here:
https://www.postgresql.org/message-id/flat/20160115175546(dot)2968(dot)6033%40wrigleys(dot)postgresql(dot)org#20160115175546(dot)2968(dot)6033(at)wrigleys(dot)postgresql(dot)org
Thought I don't think that it is that straight-forward, the relation
defined using a CTAS uses column information directly derived from the
query planned, so the fix would be to extract the necessary
information for those columns: collation, column name, type OID and
typemod without the need of the existing routines.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | zzia88 | 2016-06-14 09:07:30 | BUG #14187: Function is running correct but not showing output |
Previous Message | Peter Tripp | 2016-06-13 23:52:46 | Re: BUG #14150: Attempted to delete invisible tuple |