Search Postgresql Archives

Re: Filling Missing Primary Key Values

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 11 Aug 2011, Steve Atkins wrote:

This will fail if any of the existing values are integers in the range that
you're inserting - and it may fail in the future, as you add new records
if they clash with existing entries.

Steve/Chris/Dave:

  I had not looked in deatil at that column before. Having just done this, I
see that it's really a laboratory number, not a unique sample ID. So, I
renamed sample_id to lab_nbr, added a sample_id column, created the sequence
sample_id_seq, updated the table with it, then added the constraint that
sample_id is the primary key.

  Thank you all very much!

Rich

--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux