mirror of
https://github.com/sosedoff/pgweb.git
synced 2024-12-15 11:52:12 +03:00
Exclude pg_temp tables from other queries
This commit is contained in:
parent
82e9b1cf88
commit
4c3aa85a4e
@ -20,7 +20,7 @@ WITH all_objects AS (
|
||||
pg_catalog.pg_namespace n ON n.oid = c.relnamespace
|
||||
WHERE
|
||||
c.relkind IN ('r','v','m','S','s','')
|
||||
AND n.nspname !~ '^pg_toast'
|
||||
AND n.nspname !~ '^pg_(toast|temp)'
|
||||
AND n.nspname NOT IN ('information_schema', 'pg_catalog')
|
||||
AND has_schema_privilege(n.nspname, 'USAGE')
|
||||
|
||||
@ -38,7 +38,7 @@ WITH all_objects AS (
|
||||
JOIN
|
||||
pg_catalog.pg_proc p ON p.pronamespace = n.oid
|
||||
WHERE
|
||||
n.nspname !~ '^pg_toast'
|
||||
n.nspname !~ '^pg_(toast|temp)'
|
||||
AND n.nspname NOT IN ('information_schema', 'pg_catalog')
|
||||
)
|
||||
SELECT * FROM all_objects
|
||||
|
Loading…
Reference in New Issue
Block a user