Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
# build multidimensional array from results while (@arr = $sel->fetchrow_array) { push (@drivers, \@arr); # prints the correct data from the db print "arr: @arr\n"; } # prints the right number of ref's print @drivers; # this just prints the commas and the spaces foreach my $item (@drivers) { print "$item->[0], $item->[1], $item->[2]"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
•Re: Array of Arrays from DB
by merlyn (Sage) on May 30, 2002 at 19:35 UTC | |
by Anonymous Monk on May 30, 2002 at 21:57 UTC | |
|
Re: Array of Arrays from DB
by abaxaba (Hermit) on May 30, 2002 at 20:40 UTC | |
|
Re: Array of Arrays from DB
by fenonn (Chaplain) on May 30, 2002 at 20:43 UTC |