Re: timestamp as primary key?

Поиск
Список
Период
Сортировка
От Tomasz Ostrowski
Тема Re: timestamp as primary key?
Дата
Msg-id 20061019112713.GA12073@batory.org.pl
обсуждение исходный текст
Ответ на timestamp as primary key?  ("Joe Kramer" <cckramer@gmail.com>)
Ответы Re: timestamp as primary key?  ("John D. Burger" <john@mitre.org>)
Список pgsql-general
On Thu, 19 Oct 2006, Joe Kramer wrote:

> Question: is it okay to use timestamp as primary key, or there is
> possibility of collision? (Meaning two processes may INSERT into table
> within same millisecond.) It is a web application.

If your insert fail you can always try again after some random short
time. Just do that several times and if it fails, say, 5 times
show an error to a user (sugest him to try a lottery - he'll surely
win ;-) ).

Regards
Tometzky
--
...although Eating Honey was a very good thing to do, there was a
moment just before you began to eat it which was better than when you
were...
                                                      Winnie the Pooh

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

Предыдущее
От: "Joe Kramer"
Дата:
Сообщение: timestamp as primary key?
Следующее
От: "Peter Bauer"
Дата:
Сообщение: Overload after some minutes, please help!