Re: updating a row referenced by a foreign key - Mailing list pgsql-general

From Craig Ringer
Subject Re: updating a row referenced by a foreign key
Date
Msg-id 483043D8.7020103@postnewspapers.com.au
Whole thread Raw
In response to updating a row referenced by a foreign key  ("Michael P. Soulier" <michael_soulier@mitel.com>)
List pgsql-general
Michael P. Soulier wrote:

> Is there a simple way to update the row, and cascade the change to any
> and all rows referencing this row as a foreign key? I searched on
> cascade in the postgres docs and while I found references to deletion, I
> didn't find one for updates.

http://www.postgresql.org/docs/current/static/ddl-constraints.html#DDL-CONSTRAINTS-FK

"Analogous to ON DELETE there is also ON UPDATE which is invoked when a
referenced column is changed (updated). The possible actions are the same."

--
Craig Ringer

pgsql-general by date:

Previous
From: "Michael P. Soulier"
Date:
Subject: updating a row referenced by a foreign key
Next
From: Teodor Sigaev
Date:
Subject: Re: tsearch2 on-demand dictionary loading & using functions in tsearch2