Re: query multiple databases

From: Keary Suska <hierophant(at)pcisys(dot)net>
To: PostgreSQL <pgsql-general(at)postgresql(dot)org>
Subject: Re: query multiple databases
Date: 2001-10-01 20:14:53
Message-ID: B7DE2ADD.3F11%hierophant@pcisys.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> My existing app uses lots of SQL that query 2 or more seperate databases. I
> have just read that this can;t be done in postgreSQL. Is this true?

Yes. IIRC, Postgres only validates access on connection. With psql you can
switch between databases, but I don't know if that feature is available
through other means such as PHP or DBI.

> If so, are there any obvious work-arounds? Or must I simply combine all my
> databases into one? I really don't want to do that!

Your best bet would probably be multiple connections. As you can see, there
would be no way to combine results from different connections/databases
except in the application, and you would not be able to do cross-database
joins, so you would have to alter your application logic

> If this limitation exists, can anybody recomend another database that
> doesn't cost a fortune but has similar strength-of-features to
> MS-SQL/postgreSQL?

Although I am an open-source advocate, I am also a businessman, and although
you could get Postgres to do what you need relatively efficiently, sometimes
the time needed to implement workarounds makes Postgres simply not cost
effective. When I can't fall back on open source, I fall back to the
underdogs with good products. One I can recommend is FrontBase
(http://www.frontbase.com). For about $1k you get 100% SQL92 compliance,
replication, live backup, and no per-seat or any other additional costs.
<DISCLAIMER>I have no relationship with the company and no extensive
production experience with the DB system. I cannot vouch for the stability,
security, or ability to service customers. My recommendation is based on
research and testing only.</DISCLAIMER>

Keary Suska
Esoteritech, Inc.
"Leveraging Open Source for a better Internet"

> From: "Adam Fisher" <black(at)cia(dot)com(dot)au>
> Organization: Hub.Org Networking Services (http://www.hub.org)
> Date: Thu, 27 Sep 2001 17:06:35 +1000
> To: pgsql-general(at)postgresql(dot)org
> Subject: [GENERAL] query multiple databases

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Keary Suska 2001-10-01 20:52:50 Re: Connection to database 'template1' failed.
Previous Message Cary Lewis 2001-10-01 19:35:09 windows ce version of postgresql