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

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Reply via email to