Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re: Code factoryby tadman (Prior) |
on Jul 08, 2003 at 19:01 UTC ( [id://272388]=note: print w/replies, xml ) | Need Help?? |
If I recall correctly, DBI recycles the hash reference with each iteration. What you end up with is an ARRAY of exactly the same HASH data. You should duplicate it, as was done with that first bit of code, or better yet:
push(@$results, { %$row });
In Section
Seekers of Perl Wisdom
|
|