Search Postgresql Archives

Re: grant connect to all databases

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Saturday, October 5, 2024, Matt Zagrabelny <mzagrabe@xxxxxxxxx> wrote:
Hello,

I'd like to have a read-only user for all databases.

I found the pg_read_all_data role predefined role, which I granted to my RO user:

GRANT pg_read_all_data TO ro_user;

...but I cannot connect to my database(s).

I'd like to not have to iterate over all the databases and "GRANT CONNECT...".

Is there a way to do this with just one GRANT or equivalent command?


The pseudo-role Public exists for just this kind of thing.  In fact, in a default installation it already is given connect privileges on all databases created by the bootstrap superuser.

David J.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux