From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Jordan Gigov <coladict(at)gmail(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_restore misuse or bug? |
Date: | 2017-07-21 14:03:23 |
Message-ID: | 29286.1500645803@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Jordan Gigov <coladict(at)gmail(dot)com> writes:
> When running pg_restore as the superuser it gives the following error
> pg_restore: [archiver (db)] Error while PROCESSING TOC:
> pg_restore: [archiver (db)] Error from TOC entry 3253; 0 320628
> MATERIALIZED VIEW DATA combined_query_data web_user
> pg_restore: [archiver (db)] could not execute query: ERROR:
> permission denied for relation first_table_in_from_list
> Command was: REFRESH MATERIALIZED VIEW combined_query_data;
What PG version is this? Can you provide a self-contained test case?
> I see no reason why the superuser would get a "permission denied"
> error.
Matview queries are run as the owner of the matview, so this isn't
as surprising as all that. But if the matview works in your normal
usage, then pg_dump must be doing something wrong, perhaps emitting
grants in the wrong order.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Andreas Kretschmer | 2017-07-21 14:07:29 | Re: Schemas and foreign keys |
Previous Message | marcelo | 2017-07-21 12:58:00 | Schemas and foreign keys |