Jeffrey Walton <noloader(at)gmail(dot)com> writes:
> I have another beginner question. I am trying to use pg_isready to
> determine if a database and user are present. The program seems to
> always succeed, even when I delete the user or the database.
That's a feature actually. The intended use of pg_isready is to
find out if the server is alive, not whether any particular user
or database name is correct. So it treats responses like "no such
database" as sufficient proof that the server is alive.
As David says, you could try to log in with any other client
software, or connect using known-good parameters and check
the system catalogs.
regards, tom lane