From: | Jesus Aneiros <aneiros(at)jagua(dot)cfg(dot)sld(dot)cu> |
---|---|
To: | Sandis <sandisj(at)parks(dot)lv> |
Cc: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: data integrity |
Date: | 2000-08-15 13:04:40 |
Message-ID: | Pine.LNX.4.10.10008150859590.18339-100000@jagua.cfg.sld.cu |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
On Tue, 15 Aug 2000, Sandis wrote:
> there is a db with a few tables that have related (joined) fields. if
> record in a one table (auxiliary) gets deleted (along with it's
I would say this is the primary table.
> primary key), reference to it in another table (main) points to
And this is the secondary tab,le which references the other.
> what's the solution? should i check if this 'project', for example,
The solution is called referential integrity. you should use the foreign
key and references clause with cascade.
> can someone suggest some good online resource where such common sql topics
> discussed?
I would like to know such a place.
Jesus.
From | Date | Subject | |
---|---|---|---|
Next Message | Sandis | 2000-08-15 13:12:53 | Re[2]: data integrity |
Previous Message | Adam Lang | 2000-08-15 12:29:23 | Re: copy from |