Re: primary key and existing unique fields

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: primary key and existing unique fields
Дата
Msg-id 20041028174400.GC12318@wolff.to
обсуждение исходный текст
Ответ на Re: primary key and existing unique fields  ("Sally Sally" <dedeb17@hotmail.com>)
Список pgsql-general
On Thu, Oct 28, 2004 at 14:31:32 +0000,
  Sally Sally <dedeb17@hotmail.com> wrote:
> Dawid,
> I am interested in the first point you made that:
> having varchar(12) in every referencing table, takes more storage
> space.
> The thing is though, if I have a serial primary key then it would be an
> additional column. Or you are saying the space taken by a VARCHAR(12) field
> is more than two INT fields? ( or is it the fact that when it is referenced
> it will appear several times?) I guess the reason I am resisting the idea
> of an additional primary key field is to avoid the additional lookup in
> some queries. Perhaps it's a minor almost irrelevant performance factor.

I think it is better to worry about what is going to make it easiest to
have clean data and to support future changes than worry about performance.
Over the long run hardware is cheaper than people.

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

Предыдущее
От: "Froggy / Froggy Corp."
Дата:
Сообщение: Re: [pgsql-fr-generale] Problème dethreadPostgresql
Следующее
От: Michael Fuhr
Дата:
Сообщение: Re: field incrementing in a PL/pgSQL trigger