<? $i = 0; $sql = "SELECT a,b,c FROM foo"; $res = mysql_query($sql); while($myrow = mysql_fetch_array($res)) { $i++; echo $i."<br />"; echo $myrow['a'] ."<br />"; echo $myrow['b'] ."<br />"; echo $myrow['c'] ."<br />"; } ?>
Justin
On Monday, August 4, 2003, at 05:34 PM, Ben C. wrote:
How do I add a column of numbers generated through a MySQL query without
using the SQL SUM() function? I have tried looking through the different
documentation. I am probably missing something.
Thanks,
Ben
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
--- [This E-mail scanned for viruses]
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php