Perl-Sensitive Sunglasses | |
PerlMonks |
sorting return fromby Anonymous Monk |
on Sep 02, 2005 at 21:20 UTC ( [id://488795]=perlquestion: print w/replies, xml ) | Need Help?? |
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Hi, I make a request from a mysql table using the following function - my $hashrow = $sth->fetchrow_hashref; The data being returned should consist of x number of rows organised into 3 columns. The first column refers to a name, and the second two columns contain their age and height. I now wish to generate the following output from my request - Name: Age, Height John 34, 154 Michael 45, 176 Sinead 31, 159 James 23, 171 etc. How do I do this using the returned hash reference? I'll need to look though the hash using a foreach statment fo starters. Thanks.
Back to
Seekers of Perl Wisdom
|
|