Re: Roll Back dont roll back counters

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Roll Back dont roll back counters
Дата
Msg-id 20010816211440.A17377@svana.org
обсуждение исходный текст
Ответ на Roll Back dont roll back counters  ("Ben-Nes Michael" <miki@canaan.co.il>)
Ответы Re: Roll Back dont roll back counters  ("Roderick A. Anderson" <raanders@tincan.org>)
Список pgsql-general
On Thu, Aug 16, 2001 at 01:15:13PM +0300, Ben-Nes Michael wrote:
> If I design a table with SERIAL type and then try to insert few rows, but
> some of the rows are rolled back the roll back process does not roll back
> the counter status.
>
> Is there a way to do a roll back to the counter ?

Nope. You can use setval, but you have no guarentees.

Think about it. If you had to roll back the counter if the transaction
failed, you would lose concurrency. Every transaction would have to wait
until the previous one finished to find out what number it will get.

Why do people care about holes anyway? I've never understood that...

--
Martijn van Oosterhout <kleptog@svana.org>
http://svana.org/kleptog/
> It would be nice if someone came up with a certification system that
> actually separated those who can barely regurgitate what they crammed over
> the last few weeks from those who command secret ninja networking powers.

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

Предыдущее
От: newsreader@mediaone.net
Дата:
Сообщение: Re: select distinct and order by
Следующее
От: Gunnar Rønning
Дата:
Сообщение: Re: Re: Re: Storing images in PG?