NikhilS <nikkhils@gmail.com> writes:
> On Fri, Mar 7, 2008 at 6:37 AM, Bruce Momjian <bruce@momjian.us> wrote:
>> Added to TODO:
>> o Require all CHECK constraints to be inherited
> PFA, a small patch attached which should fix this.
If it's a small patch, it's wrong by definition. AFAICS there is no way
to fix this correctly that doesn't involve catalog changes. The point
of the TODO is that you have to enforce that the inherited constraint
sticks around, eg can't be dropped on a child table while it's still
present on the parent. There are implications for pg_dump too.
regards, tom lane