If there is an error function mysql_result then it returns 0?
I looked everywhere but i could not find an answer ….
<?php
include "config.php";
$result = mysql_query("SELECT `price` FROM `prices` where bin = 1 limit 0,10" ) ;
$i=0;
$d=0;
while($i!=10){
$d=$d+mysql_result($result, $i)or die($d);
$i++;
}
?>
its returns 7 errors …
( ! ) Warning: mysql_result() [function.mysql-result]: Unable to jump
to row 3 on MySQL result index 5 in C:\wamp\www\fom\Untitled 1.php on
line 7
Try this: