Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Hash to Scalar?

by ph0enix (Friar)
on Dec 09, 2002 at 13:43 UTC ( #218515=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use Storable qw(nfreeze thaw);
    $scalar = nfreeze(\%hash);
    %hash_copy = %{ thaw($scalar) };
    
  2. or download this
    use Tie::RDBM;
    tie %h,Tie::RDBM,'mysql:test',{table=>'Demo',create=>1,autocommit=>0};
    $h{'key1'} = 'Some data here';
    ...
    print $h{'key3'}->{complex}->[0];
    tied(%h)->commit;
    untie %h;
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (1)
As of 2023-09-21 19:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?