fetchrow_hashref Question
From: Gohaku (gohaku_at_earthlink.net)
Date: 12/23/03
- Previous message: Amanullah: "Re: looping error message"
- Next in thread: Paul Boutros: "RE: fetchrow_hashref Question"
- Reply: Paul Boutros: "RE: fetchrow_hashref Question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 23 Dec 2003 12:28:46 -0500 To: dbi-users@perl.org
Hi everyone,
I just found out about fetchrow_hashref after using fetchrow_array for
quite a while now. I have some questions about the following code:
while ( my $row = $sth->fetchrow_hashref ) {
print "New User:\n";
foreach my $field ( sort keys %{ $row } ) {
print "$field: $row->{ $field }\n";
}
}
If I try to print $row{$field}, I don't see anything, why is that?
Thanks in advance.
-gohaku
- Previous message: Amanullah: "Re: looping error message"
- Next in thread: Paul Boutros: "RE: fetchrow_hashref Question"
- Reply: Paul Boutros: "RE: fetchrow_hashref Question"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]