pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Josh Berkus <josh@agliodbs.com>
To: bob lapique <lapique@chez.com>
To: pgsql-sql <pgsql-sql@postgresql.org>
Subject: Re: sharing data accross several databases
Date: Tue, 22 Jan 2002 15:05:33 -0800
Message-ID: <web-673532@davinci.ethosmedia.com> (raw)
In-Reply-To: <GQCBOL$Ian3fEvZaErv5KfFYVf_mG14AhHTzzHRycHQ8jPZa0N@tiscali.fr>

Bob,
 
> I am designing 2 databases :
 > - the 1st relates to flasks
 > - the 2nd relates to cylinders
 > 
> Both flasks and cylinders will be shipped accross the 
> world and I need to keep track of check out dates, 
> shipping method, destination, etc. These data will be of 
> the same type for both databases.
 
So, why are you designing two seperate databases? It seems to me that
  you only need one database, with relevant tables carrying a "Type"
  column of "Flask" or "Cylinder". Seperate databases will give you all
  kinds of headaches you don't need.
 
> Questions :
 > -----------
 > 1) Is a 3rd database the solution ?
 
No. One, single, database is the solution.
 
> 2) I would like to keep on using foreign keys (e.g. 
> between a shipped item and the destination location)
 
PostgreSQL does not permit access of multiple databases from SQL (this
  was a design decision, based on the project's interpretation of the
  SQL92 standard). If you pursue you current approach, you will be
  forced to use middleware (such as JSP or J2EE or Perl::DBI) to access
  both of your databases at once ... considerable trouble for no
  benefit.
 
-Josh Berkus

______AGLIO DATABASE SOLUTIONS___________________________
                                       Josh Berkus
  Complete information technology      josh@agliodbs.com
   and data management solutions       (415) 565-7293
  for law firms, small businesses        fax 621-2533
    and non-profit organizations.      San Francisco



view thread (3+ messages)  latest in thread

Message-ID: <web-673532@davinci.ethosmedia.com>
Permalink:  ../web-673532@davinci.ethosmedia.com/
Also on:    postgresql.org/message-id/web-673532@davinci.ethosmedia.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: josh@agliodbs.com, lapique@chez.com
  Subject: Re: sharing data accross several databases
  In-Reply-To: <web-673532@davinci.ethosmedia.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox