Re: Strategy for Primary Key Generation When Populating Table

Поиск
Список
Период
Сортировка
От Rich Shepard
Тема Re: Strategy for Primary Key Generation When Populating Table
Дата
Msg-id alpine.LNX.2.00.1202090905170.5256@salmo.appl-ecosys.com
обсуждение исходный текст
Ответ на Re: Strategy for Primary Key Generation When Populating Table  (Merlin Moncure <mmoncure@gmail.com>)
Ответы Re: Strategy for Primary Key Generation When Populating Table
Список pgsql-general
On Thu, 9 Feb 2012, Merlin Moncure wrote:

> The record should be logically unique as well as physically unique (of if
> it isn't, why bother making a unique constraint at all?). Sometimes you
> *have* to force a surrogate, for example if certain (broken) client tools
> need a primary key to work, but aside from that you shouldn't rely on a
> surrogate to generate uniqueness.

merlin,

   I have reports containing macroinvertebrate collection data for several
hundred (or several thousand) of taxa. There is no natural key since there
are multiple rows for each site/date pair. Years ago Joe Celko taught me to
seek natural keys whenever they might exist. They don't here. That's why I
specifically mentioned that in my message.

   The only 'broken client tools' are their consistent uses of Microsoft
Excel to store data or providing text reports in pdf with other data.

Rich



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

Предыдущее
От: Merlin Moncure
Дата:
Сообщение: Re: Strategy for Primary Key Generation When Populating Table
Следующее
От: Andy Colson
Дата:
Сообщение: Re: Strategy for Primary Key Generation When Populating Table