Search Postgresql Archives

Re: Choosing primary key type: 64 or 52 bit primary keys?

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

 



I think there is no difference in indexing int or floats. Only one difference is speed of comparison of this numbers.

If you create normal system use 64bit ints.  

------------------------
Regards,
Radoslaw Smogura
(mobile)

-----Original Message-----
From: Antonio Vieiro
Sent: 22 lipca 2011 09:01
To: pgsql
Subject:  Choosing primary key type: 64 or 52 bit primary keys?

Hi all,

I'd like to use an integer number for my primary key. I need it to be
bigger than 32 bits.

As far as I understand I have two options:

a) use all the 64 bits of a 'bigint'
b) use the 52 mantissa bits of a 'double precision'

My question is, which would be faster for indexing? I assume the
bigint wins here, right?

Thanks in advance,
Antonio

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



-- 
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