Re: IS it a good practice to use SERIAL as Primary Key?

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: IS it a good practice to use SERIAL as Primary Key?
Дата
Msg-id 20061123164910.GA14956@svana.org
обсуждение исходный текст
Ответ на Re: IS it a good practice to use SERIAL as Primary Key?  (Ron Johnson <ron.l.johnson@cox.net>)
Ответы Re: IS it a good practice to use SERIAL as Primary Key?  (Ron Johnson <ron.l.johnson@cox.net>)
Список pgsql-general
On Thu, Nov 23, 2006 at 10:23:55AM -0600, Ron Johnson wrote:
> For those times when and that when numeric sequences *are* needed
> (employee_id and account_number for example) they should include a
> check digit, to ensure that you don't mis-type a number and charge
> the wrong account.

Sure, but the check digit does not need to be stored, as it can be
regenerated on demand. The user interface just verifies the check
digit, then throws it away.

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Вложения

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

Предыдущее
От: Ron Johnson
Дата:
Сообщение: Re: IS it a good practice to use SERIAL as Primary Key?
Следующее
От: Martijn van Oosterhout
Дата:
Сообщение: Re: COPY FROM : out of memory