| From: | Mike Haberman <mikeh(at)ncsa(dot)uiuc(dot)edu> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | pgsql-general(at)postgresql(dot)org |
| Subject: | Re: FOREIGN KEY migration of syntax, help needed |
| Date: | 2007-07-31 20:34:56 |
| Message-ID: | 20070731203456.GA44839@ncsa.uiuc.edu |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Thank you for the quick response.
If all my old constraints are NOT DEFERRABLE INITIALLY IMMEDIATE
does that mean I don't have to worry about the deferrable keyword?
mike
On Tue, Jul 31, 2007 at 04:00:59PM -0400, Tom Lane wrote:
> Mike Haberman <mikeh(at)ncsa(dot)uiuc(dot)edu> writes:
> > Will the following take care of all three statements?
>
> > ALTER TABLE ONLY assettype
> > ADD CONSTRAINT at_fk_1 FOREIGN KEY (pid) REFERENCES assettype(id)
> > ON UPDATE CASCADE ON DELETE CASCADE;
>
> Yes, there are three or so triggers under the hood of any FOREIGN KEY
> constraint.
>
> regards, tom lane
--
-----------------------------------------------------------------------
Mike Haberman
Senior Software/Network Research Engineer
National Center for Supercomputing Applications
217.244.9370
-----------------------------------------------------------------------
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Richard Broersma Jr | 2007-07-31 21:59:41 | Re: plperl syntax highlighting for vi |
| Previous Message | Tom Lane | 2007-07-31 20:29:52 | Re: continue in plpgsql 7.4 |