Re: Behavior of GENERATED columns per SQL2003

Поиск
Список
Период
Сортировка
От Zoltan Boszormenyi
Тема Re: Behavior of GENERATED columns per SQL2003
Дата
Msg-id 4642DE73.4040809@cybertec.at
обсуждение исходный текст
Ответ на Re: Behavior of GENERATED columns per SQL2003  (Zoltan Boszormenyi <zb@cybertec.at>)
Список pgsql-hackers
Zoltan Boszormenyi írta:
> The quoted SIGMOD paper mentioned that specifying a value
> for a generated column should raise an error in INSERT but
> this behaviour is not mentioned by the standard.

I found it now, I haven't read hard enough before.
SQL:2003, section 14.8, syntax rules:

10) If <contextually typed table value constructor> CTTVC is specified, 
then every <contextually typed row   value constructor element> simply contained in CTTVC whose 
positionally corresponding <column name>   in <insert column list> references a column of which some underlying 
column is a generated column shall   be a <default specification>.

So, I can only omit the generated column or specify DEFAULT.
Anything else should raise an error. Should it be done in analyze.c
or in rewriteHandler.c?

-- 
----------------------------------
Zoltán Böszörményi
Cybertec Geschwinde & Schönig GmbH
http://www.postgresql.at/



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Zoltan Boszormenyi
Дата:
Сообщение: Re: Behavior of GENERATED columns per SQL2003
Следующее
От: "Valentine Gogichashvili"
Дата:
Сообщение: Re: [PERFORM] Cannot make GIN intarray index be used by the planner