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

Re: Strict, cant use string as hash ref

by moritz (Cardinal)
on Dec 09, 2009 at 12:15 UTC ( [id://811907]=note: print w/replies, xml ) Need Help??


in reply to Strict, cant use string as hash ref

Instead of storing the name of a hash in a variable, use a nested hash:
use strict; my %hash; my $server="jwesvsf7"; my $timestamp = "123433"; my $attribute="CPU_USER"; my $key =$attribute."_".$server; $hash{$key}{key} = 'value';

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2024-04-16 12:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found