
June 2nd, 2000, 08:49 PM
|
|
Junior Member
|
|
Join Date: Jun 2000
Posts: 16
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by rtna:
$sql="SELECT free,other,url,image FROM userdb where 1 and webadv like "ON" and active like "YES"";
$sth = $dbh->prepare($sql);
$rv = $sth->execute;
@row=$sth->fetchrow_array();
print @row; # it's 1st record[/quote]
And why not: ps. don't use "while((@row)=$sth->fetchrow)"
Buy a book. page 131,132 of "Programming the Perl DBI" describe just how to do that. It is under the header "Batch Fetching". Good book worth the money.
Peter
|