Re: Table inheritance surprise - Mailing list pgsql-hackers

From Decibel!
Subject Re: Table inheritance surprise
Date
Msg-id 8CE09ABF-3462-4EA5-A7E2-ABD06BB24FC9@decibel.org
Whole thread Raw
In response to Table inheritance surprise  (David Fetter <david@fetter.org>)
List pgsql-hackers
On May 7, 2008, at 4:52 PM, David Fetter wrote:
> When I do CREATE TABLE foo(LIKE bar INCLUDING CONSTRAINTS), it doesn't
> include foreign key constraints (8.3.1).  I believe this is surprising
> behavior, but maybe not a bug, so I'd like to propose another bit of
> syntactic sugar, namely
>
>     LIKE [INCLUDING FOREIGN KEYS]
>
> which would do what it looks like it does.


It's surprising to me that INCLUDING CONSTRAINTS doesn't include FK  
constraints... is there a reason not to? Perhaps we should just  
change INCLUDING CONSTRAINTS to do that...
-- 
Decibel!, aka Jim C. Nasby, Database Architect  decibel@decibel.org
Give your computer some brain candy! www.distributed.net Team #1828



pgsql-hackers by date:

Previous
From: David Fetter
Date:
Subject: Re: Auto-updated fields
Next
From: Tom Lane
Date:
Subject: Re: constraint exclusion analysis caching