Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: DBI Hash of Column name values

by avrono (Novice)
on Aug 09, 2010 at 19:59 UTC ( #853907=note: print w/replies, xml ) Need Help??


in reply to Re: DBI Hash of Column name values
in thread DBI Hash of Column name values

So $rows is a ref to an Array of Hashes ?

Replies are listed 'Best First'.
Re^3: DBI Hash of Column name values
by Anonymous Monk on Aug 09, 2010 at 20:05 UTC
      Thanks for all the wisdom ! I am not sure how efficient my final solution is, but I wanted an array of hashes. This works
      my %rec; $sth->bind_columns (\(@rec{@{$sth->{NAME_lc}}})); while ($sth->fetch) { my %res = %rec; push(@result, \%res); } return \@result;

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2018-08-15 11:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Asked to put a square peg in a round hole, I would:









    Results (160 votes). Check out past polls.

    Notices?