Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight

Re: use of unitialized value

by robartes (Priest)
on Oct 20, 2003 at 18:10 UTC ( #300691=note: print w/ replies, xml ) Need Help??

in reply to use of unitialized value

Try dumping the contents of $inventory{$itemcode} to see what's actually in it (using Data::Dumper:

print Dumper($inventory{$itemcode}); # or even: print Dumper(\%inventory);
That way, you can verify that the hash values contain what you think they contain.


Comment on Re: use of unitialized value
Select or Download Code
Replies are listed 'Best First'.
Re: Re: use of unitialized value
by madaket (Novice) on Oct 20, 2003 at 18:53 UTC

    The funny thing about this error message is that it happens whether there is a value in

    or not. The loop will generate the error in each iteration.
    The value is from a web page form input, so I thought the problem might be a string/number conversion, but the error message doesn't indicate that.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2015-11-30 23:38 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (788 votes), past polls