Re: Retrieving result of COUNT(*) with PHP

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Wednesday 28 March 2007 14:31, "Valentín Orfila" 
<valentinorfila@xxxxxxxxx> wrote:
> Where people this the way I do, count (*) could be slower
>
> <?
> $sql = "select * from TableName";
> $count = pg_query($sql);
> $count = pg_num_rows($count);
> ?>
> <td ><?=$count?></td>
>
> I thing that's enough :)

Apparently you have no tables with any real amount of data in them.

-- 
"It is a besetting vice of democracies to substitute public opinion for
law." - James Fenimore Cooper 



[Index of Archives]     [Postgresql General]     [Postgresql Admin]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Backpacking]     [Postgresql Jobs]

  Powered by Linux