in reply to Rows Count Issue Help!
fetchrow_hashref() fetches the next row of data and returns it as a reference to a hash containing field name and field value pairs.$sth = $dbh->prepare("select count(distinct all_id) as a from users") +or die ("Error in SQL\n"); $sth->execute(); my $counts = $sth->fetchrow_hashref(); print "There are ".$counts->{'a'}." in this table";
|
|---|