Search Postgresql Archives

Re: Determine if a user and database are available

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

 



On Friday, September 2, 2022, Jeffrey Walton <noloader@xxxxxxxxx> wrote:

Given the NOTES in the man page, how do we determine if a user and
database are present using the shell? Is there another utility we
should be using?

Literally every other shell program that requires logging into the database will fail if invalid credentials are provided.

Or, you can use good credentials and psql to connect to a known database and then query the system to learn, without an error, if other roles or databases exist in the same cluster.

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