Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re: Trimming hash based on element uniqueness

by injunjoel (Priest)
on Jun 17, 2008 at 21:47 UTC ( #692595=note: print w/ replies, xml ) Need Help??

in reply to Trimming hash based on element uniqueness

Greetings, you might try making the keys of your hash the query, or perhaps a hash of references to your data with the query as the key, that way you can't have duplicates (like an pseudo-index of your larger structure where each element is a reference to the actual data, keyed of course by the query). The point is to construct a key that will collapse your slight variants of your queries, while still being distinct enough to not collapse everything. Have a look at The Uniqueness of hashes. if you have time.


"I do not feel obliged to believe that the same God who endowed us with sense, reason and intellect has intended us to forego their use." -Galileo

Comment on Re: Trimming hash based on element uniqueness

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://692595]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (10)
As of 2015-12-01 20:25 GMT
Find Nodes?
    Voting Booth?

    My keyboard shows this many letters:

    Results (26 votes), past polls