Skip site navigation (1) Skip section navigation (2)

Re: Primary Keys

From: Nabil Sayegh <postgresql(at)e-trolley(dot)de>
To: Farid Khan <Farid(dot)Khan(at)rogers(dot)com>,pgsql-novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Primary Keys
Date: 2003-11-09 20:22:42
Message-ID: 3FAEA212.8060706@e-trolley.de (view raw or flat)
Thread:
Lists: pgsql-novice
Farid Khan wrote:
> The table I am creating would be based on a X,Y point.  We have serious
> doubts on what this would do to the performance of the system we are
> developing.  I am assuming, that a table can have a primary key consisting
> of 2 fields, which together would be unique to the entire table.  Would
> indexing this table be the nightmare we think it would be?  Has anyone seen
> anything remotely similar out there with 1M+ rows?

Personally I would always choose an extra SERIAL column.
I don't really like the concept of having multiple columns as a PK.

1M doesn't sound like a big problem.

-- 
  e-Trolley Sayegh & John, Nabil Sayegh
  Tel.: 0700 etrolley /// 0700 38765539
  Fax.: +49 69 8299381-8
  PGP : http://www.e-trolley.de


In response to

Responses

pgsql-novice by date

Next:From: Josh BerkusDate: 2003-11-09 21:33:47
Subject: Re: Primary Keys
Previous:From: Michael GrantDate: 2003-11-09 19:15:18
Subject: 'pg_ctl status' not working

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group