Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re^4: PSQL and many queries

by jfroebe (Parson)
on Mar 24, 2009 at 13:25 UTC ( #752863=note: print w/replies, xml ) Need Help??

in reply to Re^3: PSQL and many queries
in thread PSQL and many queries

No values are required for lookup purposes. And the length of the keys makes surprisingly little difference to the size of the hash.

For example: For a hash with 11,881,376 keys:

  • From 5-bytes keys (the minimum required) to 14-bytes keys, the memory required remains almost static at 1.7GB.
  • From 15-bytes through 29-bytes, it goes to 1.9 GB.
  • From 30-bytes through 46-bytes, it goes to 2.1 GB.
  • from 47-bytes .... , it goes to 2.3 GB.

So if I have 11,881,376 keys with an average key size of say 250 bytes it would only be 2.3 GB? Same with 400 bytes? Or 500 bytes?

Jason L. Froebe

Blog, Tech Blog

Replies are listed 'Best First'.
Re^5: PSQL and many queries
by BrowserUk (Pope) on Mar 24, 2009 at 14:00 UTC

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://752863]
[Your Mother]: HA.
[NodeReaper]: he's already hiding from me :(
[Corion]: Your Mother: Even I don't remember what "related and neat" I could have that would fit to 1211240 :) Maybe "pjax", which turns a static site into a Javascript-partial -reloading site? That's purely Javascript though
[LanX]: true I might get visa problems when they hear about my love for massacres ...
[Your Mother]: Corion, it was something similar to Cometd/Websockets.
LanX is reminded that public sarcasm is causing rpoblems nowadays ... ehm ...
[Your Mother]: Americans love massacres as long as it's brown and red people. Ooops. That was supposed to be a state secret. There goes my Q clearance.
[Your Mother]: It would hillarious to learn the Flat Earth movement was started by misunderstood sarcasm.
[Corion]: Your Mother: Aah - Server Side Events maybe, which mostly sends events from the server as they come up?

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (11)
As of 2018-03-19 13:35 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (240 votes). Check out past polls.