Serials: removing the holes? (consecutive)

Поиск
Список
Период
Сортировка
От Jean-Christian Imbeault
Тема Serials: removing the holes? (consecutive)
Дата
Msg-id 3D4B357F.1070704@mega-bucks.co.jp
обсуждение исходный текст
Ответы Re: Serials: removing the holes? (consecutive)  (Masaru Sugawara <rk73@sea.plala.or.jp>)
Список pgsql-general
Serials are a great datatype but when using them you sometimes get
non-consecutive numbers. I understand some of the reasons for this.

Is there a (simple) way to re-sequence a serial column that is the
primary key for a table so that the numbers are all consecutive?

I don't mnind having holes but once in a while I'd like to re-sequence
the table so that the current numbes in use become consecutive.

Just asking ...

Thanks!

Jc


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

Предыдущее
От: Jean-Christian Imbeault
Дата:
Сообщение: encrypted data types?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: encrypted data types?