Only view schema with USAGE privileges

This commit is contained in:
John Trengrove 2016-07-18 13:06:48 +10:00
parent 6945843c97
commit 838b275c19

View File

@ -149,6 +149,7 @@ LEFT JOIN
WHERE WHERE
c.relkind IN ('r','v','m','S','s','') AND c.relkind IN ('r','v','m','S','s','') AND
n.nspname !~ '^pg_toast' AND n.nspname !~ '^pg_toast' AND
n.nspname NOT IN ('information_schema', 'pg_catalog') n.nspname NOT IN ('information_schema', 'pg_catalog') AND
has_schema_privilege(n.nspname, 'USAGE')
ORDER BY 1, 2` ORDER BY 1, 2`
) )