Search Postgresql Archives

Re: database design questions

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

 



Alban Hertroys wrote:
Ottavio Campana wrote:
  CREATE TABLE person (
      id   SERIAL,
      name TEXT
  );

how can I do it with a INT8 instead of a INT4?

Do you really expect that sequence to reach over 2 billion? Otherwise I'd stick with the SERIAL, nothing wrong with that unless you're selling

Depends on what the dynamics of his design are.  I.e. if he frequently
creates and deletes "people", then he can consume a lot of "id-space"
even though there aren't many real people in the database itself.

Personally, I doubt this is the case.  But, can see other applications
where this could be true.  Since you can't reuse old id's, it's easier
to just use a bigger size datum than having to worry how the database
will react when/if you run out of them!

electrons seperately or something like that (hmm... how much are they? I sure could use a few extra).

Three for a quark...  keep the charge!  [sic] :>

--don



[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