pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Moray McConnachie <moray.mcconnachie@computing-services.oxford.ac.uk>
To: Chris <chris@bitmead.com>
To: James Macken <jmac@nemesis.com.au>
Cc: pgsql-sql@postgresql.org
Subject: Re: [SQL] How to set up a simple relational database
Date: Wed, 16 Feb 2000 10:34:02 -0000
Message-ID: <00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk> (raw)
References: <000801bf7860$ee1c7860$ad7d2bcb@jay>
	<38AA7601.16B5BCB6@bitmead.com>

> create table staff (name text, packageid int);
> create table package (id int, amount text);
> SELECT * from staff, package where staff.packageid=package.id;


But that omits the "establish the relationship part", by which I
suspect James means "ensure foreign key integrity".
I must I admit I would like to see a simple exposition of that (using
the refint package, presumably) for this example - or is it not worth
it if 7.0 is bringing native foreign key integrity checks?


> James Macken wrote:
> >
> > Can someone demonstrate for me how to set up a simple relational
database
> > using the psql interactive prompt and two tables.





view thread (4+ messages)  latest in thread

Message-ID: <00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk>
Permalink:  ../00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk/
Also on:    postgresql.org/message-id/00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: moray.mcconnachie@computing-services.oxford.ac.uk, chris@bitmead.com, jmac@nemesis.com.au
  Subject: Re: [SQL] How to set up a simple relational database
  In-Reply-To: <00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk>
  References: <000801bf7860$ee1c7860$ad7d2bcb@jay> <38AA7601.16B5BCB6@bitmead.com> <00da01bf7869$57d32da0$760e01a3@oucs.ox.ac.uk>

* 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