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

Re^2: perl DBI question about fetchrow_arrayref()

by sabari (Beadle)
on Apr 25, 2010 at 08:06 UTC ( #836746=note: print w/ replies, xml ) Need Help??


in reply to Re: perl DBI question about fetchrow_arrayref()
in thread perl DBI question about fetchrow_arrayref()

The issue is simple ,during the push your inserting the ref not the value .So the last value printed many time while printing ,since the array contains the only list of ref . Like what your doing during in the first print here also you needs to insert the value not ref .

Best Regards, S.Sabarinathan,


Comment on Re^2: perl DBI question about fetchrow_arrayref()
Re^3: perl DBI question about fetchrow_arrayref()
by lightoverhead (Monk) on Apr 25, 2010 at 09:46 UTC

    Thank you Sabarinathan. This thing really confuses me.

    now I understand, that when I used push, the ref finally pointed to the last record, so when I deferenced it, all the values became the last record.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2014-04-21 08:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (492 votes), past polls