Search Postgresql Archives

Which design would be faster ...

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

 



Hi

I'm creating an application that have an fixed length alphanumeric key
and each key has (currently) up to 5 fixed length alphanumeric
variables.  I was wondering which of the designs would be faster
considering that I could have about million keys...

The first design is the obvious one. create one table with ID and
"KEYNAME", and a second table which uses the ID of the first table as
foreign key to list values.

The second design is to use one table with the columns: "key",
"value1", "value2", etc...
Since it's highly unlikely that we'll ever change the number of
values, I'm ready to consider this option if it proves to be much
faster then the first design. (although I do prefer the first design
if the speed improvements is minor).

Any ideas?

Thanks in advance
--
Haim


[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