From: | Zoltan Boszormenyi <zb(at)cybertec(dot)at> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Bruce Momjian <bruce(at)momjian(dot)us>, pgsql-patches(at)postgresql(dot)org |
Subject: | Re: IDENTITY/GENERATED v36 Re: Final version of IDENTITY/GENERATED patch |
Date: | 2007-04-04 19:35:16 |
Message-ID: | 4613FDF4.50400@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
Tom Lane írta:
> Zoltan Boszormenyi <zb(at)cybertec(dot)at> writes:
>
>> So, I should allow DROP DEFAULT, implement
>> SET DEFAULT GENERATED ALWAYS AS
>> and modify the catalog so the GENERATED property
>> is part of pg_attrdef.
>>
>
> Sounds good.
>
>
>> What about IDENTITY?
>> Should it also be part of pg_attrdef? There are two ways
>> to implement it: have or don't have a notion of it.
>> The latter would treat GENERATED BY DEFAULT AS IDENTITY
>> the same as SERIAL.
>>
>
> Is there any good reason to distinguish the two?
>
Yes. Plain SERIALs can be updated with given values
whereas IDENTITY columns cannot. And there is the
difference between GENERATED and GENERATED IDENTITY:
GENERATED columns can updated with DEFAULT
values, IDENTITY columns cannot. I strictly have to
distinguish IDENTITY from both GENERATED and
plain SERIALs.
> regards, tom lane
>
--
----------------------------------
Zoltán Böszörményi
Cybertec Geschwinde & Schönig GmbH
http://www.postgresql.at/
From | Date | Subject | |
---|---|---|---|
Next Message | Markus Schiltknecht | 2007-04-04 19:40:31 | Re: Auto Partitioning |
Previous Message | Markus Schiltknecht | 2007-04-04 19:34:03 | Re: Auto Partitioning |
From | Date | Subject | |
---|---|---|---|
Next Message | Markus Schiltknecht | 2007-04-04 19:40:31 | Re: Auto Partitioning |
Previous Message | Markus Schiltknecht | 2007-04-04 19:34:03 | Re: Auto Partitioning |