Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: reading the hash information from a file

by bobf (Monsignor)
on Feb 16, 2007 at 07:14 UTC ( #600375=note: print w/ replies, xml ) Need Help??


in reply to reading the hash information from a file

I'm not exactly sure I understand your question, but if you've got a hash dumped to a file (from something like print Dumper( \%hash )) and you trust the file source, you could read it in to a string and eval it.

If you are using the file as a simplified database, you may want to consider DBM::Deep or Storable.


Comment on Re: reading the hash information from a file
Download Code
Re: reading the hash information from a file
by b10m (Vicar) on Feb 16, 2007 at 09:01 UTC

    ... or YAML

    --
    b10m

    All code is usually tested, but rarely trusted.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2015-07-05 04:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (60 votes), past polls