Re: getting currval from a sequence

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: getting currval from a sequence
Дата
Msg-id 20020211134611.GB3472@wolff.to
обсуждение исходный текст
Ответ на getting currval from a sequence  (tony <tony@animaproductions.com>)
Ответы Re: getting currval from a sequence
Список pgsql-general
On Mon, Feb 11, 2002 at 11:42:31AM +0100,
  tony <tony@animaproductions.com> wrote:
>
> How does one get the last record from a series of records? I just need
> the id field which is a sequence field

select max(id) from whatever;
(This assumes the sequence hasn't rolled over.)

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

Предыдущее
От: "Cornelia Boenigk"
Дата:
Сообщение: timespan_part()?
Следующее
От: Karel Zak
Дата:
Сообщение: Re: timespan_part()?