Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bS6EV-0003mK-DB for pgsql-bugs@arkaria.postgresql.org; Tue, 26 Jul 2016 17:33:31 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bS6EU-0000Rr-VY for pgsql-bugs@arkaria.postgresql.org; Tue, 26 Jul 2016 17:33:31 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bS6Dr-0008Av-W8 for pgsql-bugs@postgresql.org; Tue, 26 Jul 2016 17:32:52 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bS6Dp-0006tt-Om for pgsql-bugs@postgresql.org; Tue, 26 Jul 2016 17:32:50 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u6QHWlpC026376; Tue, 26 Jul 2016 13:32:47 -0400 From: Tom Lane To: Kevin Grittner cc: Peter Eisentraut , Michael Paquier , marian.krucina@gmail.com, PostgreSQL mailing lists Subject: Re: BUG #13907: Restore materialized view throw permission denied In-reply-to: References: <20160202161407.2778.24659@wrigleys.postgresql.org> <22633.1465910990@sss.pgh.pa.us> <1152.1466094507@sss.pgh.pa.us> <21147.1467052547@sss.pgh.pa.us> <9af4bc32-7e55-a21d-47e7-608582a8c48d@2ndquadrant.com> <5850.1469541250@sss.pgh.pa.us> <17767.1469546034@sss.pgh.pa.us> Comments: In-reply-to Kevin Grittner message dated "Tue, 26 Jul 2016 11:39:21 -0500" Date: Tue, 26 Jul 2016 13:32:47 -0400 Message-ID: <26375.1469554367@sss.pgh.pa.us> X-Pg-Spam-Score: -3.2 (---) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Kevin Grittner writes: > On Tue, Jul 26, 2016 at 10:13 AM, Tom Lane wrote: >> Uh ... that the owner might revoke his own SELECT privilege? > What about policies that might have changed since the latest > REFRESH before dump? How about views or functions that might have > changed? I think you're setting up straw men. No one has argued that we should dump and restore the verbatim current contents of a matview. But there is a longstanding expectation that pg_dump be able to dump and restore the contents of read-only tables, and what you proposed breaks that. That won't do. It's possible that the most reasonable fix is to move matview refreshes to after the ACL restoration step. That would wreak a lot of havoc with the current view of a dump as being tripartite (pre-data/data/post-data), so it might be more work than we want to do. But it seems like the logically soundest thing. regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs