Re: SERIAL type feature request

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: SERIAL type feature request
Дата
Msg-id 43937A4E.2020005@dunslane.net
обсуждение исходный текст
Ответ на Re: SERIAL type feature request  (Zoltan Boszormenyi <zboszor@dunaweb.hu>)
Список pgsql-hackers

Zoltan Boszormenyi wrote:

>
>
> I found this in the SQL2003 draft:
>
> "
> 4.14.7 Identity columns
>
> ... An identity column has a start value, an increment, a maximum 
> value, a minimum value,
> and a cycle option. ...



And that section says nothing at all about using 0 as a magic value. All 
it says is:

"Let IC be the identity column of BT. When a row R is presented for 
insertion
into BT, if R does not contain a column corresponding to IC, then the 
value V for IC in the row inserted into
BT is obtained by applying the General Rules of Subclause 9.21, 
“Generation of the next value of a sequence
generator”, to SG."

Which is pretty much what we do.

We can't implement everybody's way of doing serial cols, because they 
are simply not all compatible. Next someone will be asking us to do it 
MySQL's way (gods forbid).

cheers

andrew


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

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: [PATCHES] snprintf() argument reordering not working
Следующее
От: Jan Wieck
Дата:
Сообщение: Re: SERIAL type feature request