adding on delete cascade constraint? - Mailing list pgsql-general

From Jean-Christian Imbeault
Subject adding on delete cascade constraint?
Date
Msg-id 3F6AD5DD.90706@mega-bucks.co.jp
Whole thread Raw
Responses Re: adding on delete cascade constraint?
List pgsql-general
Currently I have a table defined as such:

TAL=# \d internal_keywords
Table "public.internal_keywords"
  Column  |  Type   | Modifiers
---------+---------+-----------
  keyword | text    | not null
  pid     | integer | not null
Indexes: internal_keywords_pkey primary key btree (keyword, pid)
Foreign Key constraints: $1 FOREIGN KEY (pid) REFERENCES products(id) ON
UPDATE NO ACTION ON DELETE NO ACTION

How can I change the ON DELETE action to CASCADE for column pid?

I've check the alter table documentation but cannot find any reference
to this.

Thanks,

Jean-Christian Imbeault


pgsql-general by date:

Previous
From: "Marek Lewczuk"
Date:
Subject: Zend survey result about dbms...
Next
From: Oliver Elphick
Date:
Subject: Re: adding on delete cascade constraint?