Redshift is based on a version of PostgreSQL that only allows SuperUsers to see pg_catalogĀ  objects.

Here is a way to get around that – must be a superuser to do this:

  • create group select_catalog_group;
  • grant select on all the tables in pg_catalog your users want to see (see an example list below)
  • alter group select_catalog_group add user <username>;
create group select_catalog_group;

GRANT SELECT ON TABLE pg_catalog.STL_DELETE TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_ERROR TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_FILE_SCAN TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.stl_vacuum TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_UNLOAD_LOG TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_INSERT TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_LOAD_COMMITS TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_LOAD_ERRORS TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.stl_loaderror_detail TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.STL_UNLOAD_LOG TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.pg_database TO GROUP select_catalog_group;

GRANT USAGE ON SCHEMA information_schema TO GROUP select_catalog_group;
GRANT USAGE ON SCHEMA pg_catalog TO GROUP select_catalog_group;
GRANT SELECT ON TABLE pg_catalog.pg_database TO GROUP select_catalog_group;

alter group select_catalog_group add user <your-username>;

Leave a Reply

Your email address will not be published. Required fields are marked *