Search Postgresql Archives

Re: Connect without specifying a database?

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

 



"lists@xxxxxxxxx" <lists@xxxxxxxxx> writes:
> What do you mean when you say the "catalogs...are database- 
> specific" ?  If I'm understanding what you're saying, my whole point  
> is that I don't want to be tied to a database to do any kind of  
> querying about the PG engine itself.  Does that make sense?

No, it does not.  This is perhaps an implementation quirk of Postgres's,
but it does have some advantages and we're not interested in giving them
up just because it confuses MySQLers ;-).  The main advantage is that
having separate catalogs in each database is more robust (no matter how
badly database A gets messed up, database B will be okay) and reduces
contention for catalog access.

There are a few catalogs that are visible in all databases of an
installation (pg_database itself being the most obvious one) but they
are not sufficient to support an operational backend.  So you have to
connect to some database even to query those catalogs.

We could have a convention that there is some database that you connect
to only for the purpose of inspecting pg_database, but there doesn't
seem a whole lot of point in trying to enforce that.  The standard
databases serve well enough.

			regards, tom lane

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[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 Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux