From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | Oliver Elphick <olly(at)lfix(dot)co(dot)uk> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Re: Changing the default value of an inherited column |
Date: | 2001-03-29 16:53:15 |
Message-ID: | Pine.LNX.4.30.0103291851120.2091-100000@peter.localdomain |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Oliver Elphick writes:
> Peter Eisentraut wrote:
> >Tom Lane writes:
> >
> >> It seems that in pre-7.0 Postgres, this works:
> >>
> >> create table one(id int default 1, descr text);
> >> create table two(id int default 2, tag text) inherits (one);
> >>
> >> with the net effect that table "two" has just one "id" column with
> >> default value 2.
> >
> >Although the liberty to do anything you want seems appealing at first, I
> >would think that allowing this is not correct from an OO point of view.
>
> I don't agree; this is equivalent to redefinition of a feature (=method) in
> a descendant class, which is perfectly acceptable so long as the feature's
> signature (equivalent to column type) remains unchanged.
The SQL equivalent of redefining a method would the redefinition of a
method [sic]. But since we don't have anything close to that, feel
free...
--
Peter Eisentraut peter_e(at)gmx(dot)net http://yi.org/peter-e/
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2001-03-29 16:57:20 | Re: Re: Changing the default value of an inherited column |
Previous Message | Peter Eisentraut | 2001-03-29 16:49:42 | Re: Re: [PORTS] pgmonitor and Solaris |