Thomas Swan <tswan-lst(at)tangent(dot)ics(dot)olemiss(dot)edu> writes:
> Actually, I think I understand the question. The original person wants to
> be able to do a query and get a result containing a list of
> databases. AFAIK, there isn't a way to do this using standard SQL-like
> statements. Somebody correct me if I'm wrong.
SELECT datname FROM pg_database;
I think Tim's real gripe is about having to know enough about the
contents of the system tables to be able to construct such a query.
regards, tom lane