Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Data Dumper Question

by Khen1950fx (Canon)
on Dec 27, 2009 at 07:51 UTC ( [id://814490]=note: print w/replies, xml ) Need Help??


in reply to Data Dumper Question

I went along a different route:

#!/usr/bin/perl use strict; use warnings; use Data::Dumper; my ($hash_ref, $var1, $var2); print "\n------This is my test of Data Dumper------\n\n"; $var1->{'temp'} = '123'; push (@{$hash_ref->{'test1'}}, $var1); push (@{$hash_ref->{'test2'}}, $var1); warn Dumper($hash_ref); $var2->{'temp2'} = '123'; warn Dumper($hash_ref), "\n\n"; print "----------------------------------------------\n"; exit;
Update: Using Data::Dump::Streamer instead:

#!/usr/bin/perl use strict; use warnings; use Data::Dump::Streamer; my ($hash_ref, $var1, $var2); print "\n------This is my test of Data Dumper------\n\n"; $var1->{'temp'} = '123'; push (@{$hash_ref->{'test1'}}, $var1); push (@{$hash_ref->{'test2'}}, $var1); warn Dump($hash_ref); $var2->{'temp2'} = '123'; warn Dump($hash_ref), "\n\n"; print "----------------------------------------------\n"; exit;

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2024-04-25 10:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found