Re: going crazy with serial type

Поиск
Список
Период
Сортировка
От Jan Wieck
Тема Re: going crazy with serial type
Дата
Msg-id 200201312121.g0VLLtA08512@saturn.janwieck.net
обсуждение исходный текст
Ответ на Re: going crazy with serial type  (Darren Ferguson <darren@crystalballinc.com>)
Ответы Re: going crazy with serial type  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
Darren Ferguson wrote:
> For some reason unknown to myself if you have not initiated a nextval in
> the same psql command line before calling currval then that is the error
> msg you will get.

    Slightly  wrong. This is the correct behaviour if you haven't
    called NEXTVAL in that session before.

    The reason is that the SQL standard  defines  CURRVAL  to  be
    last value returned by NEXTVAL "in this session".


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== JanWieck@Yahoo.com #



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


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

Предыдущее
От: Stephan Szabo
Дата:
Сообщение: Re: Function to Pivot data
Следующее
От: Darren Ferguson
Дата:
Сообщение: Re: Function to Pivot data