Hi, everyone,
I have a PHP-MySql statements like this:
$query="select count(*) from table1";
$result=mysql_query($query);
$count=mysql_result($result,0,0);
How can I get the $count using Perl-MySql language?
I've tired
$sql="select count (*) as count from table1";
...
print "$count";
But nothing is printed out.
I also tried:
$count=mysql_num_rows($sql);
But I was told:
Undefined subroutine &main::mysql_num_rows called.
Could you please tell me what's wrong here?
Thank you in advance.
Rong