change the query to
Code:$query = "SELECT side, twins + ' ' + tloses AS stats FROM summary ORDER BY twins ASC";
change the query to
Code:$query = "SELECT side, twins + ' ' + tloses AS stats FROM summary ORDER BY twins ASC";
easiparcel.com Shop online and ship to Jamaica
Thanks for your quick response. That error is taken care of but now i am getting this error:
Parse error: syntax error, unexpected T_WHILE in /home/www//wcc/score.php on line 15
this is line 15:
while($result = mysql_fetch_assoc($result)){
Any ideas.
"...men are that they might have joy."
Nephi
OK. NOW THIS IS WHAT I AM GETTING:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM summary ORDER BY twins ASC' at line 1
"...men are that they might have joy."
Nephi
Removed the "," from the query before FROM and now this is what i am getting:
Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/www//wcc/score.php on line 15
"...men are that they might have joy."
Nephi
could you post the select statement you're using
3.14159265358979323846264338327950288
4197169399375105820974944592307816406
28620899862803482534211706798 pi 101
Yes i did that already :$query = "SELECT side, CONCAT(twins, ' ', tloses) AS stats FROM summary ORDER BY twins ASC";
but i am getting the error:
Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/www//wcc/score.php on line 15:
<?php
include_once("conn.php");
$f = ($_GET["f"]);
$query = "SELECT side, CONCAT(twins, ' ', tloses) AS stats FROM summary ORDER BY twins ASC";
$result = mysql_query($query) or die(mysql_error());
$numR = mysql_num_rows($result);
if ($numR = 1) {
echo"success=1";
$statsarray = array();
$sidearray = array();
$x = 0; // array index
//collect returned results in associtive manner
while($result = mysql_fetch_assoc($result)){ //this is line 15
$statsarray[$x] = $result['stats'];
$sidearray[$x] = $result['side'];
$x++;
}
//to display
$loopcontrol = count($side);
for($a = 0; $a<$loopcontrol; $a++){
echo $sidearray[$a] . " " . $statsarray[$a];
}
}
else
{
echo( "success=0" );
}
// Clean up
mysql_close($dblink);
?>
"...men are that they might have joy."
Nephi
$query = "SELECT side, CONCAT(twins,' ', tloses) AS stats FROM summary ORDER BY twins ASC"; the above code is what i have. but i am still getting error.
"...men are that they might have joy."
Nephi
$query = "SELECT side, CONCAT(twins,' ', tloses) AS stats FROM summary ORDER BY twins ASC"; this is what i have and i am still getting error.
this is the error:
Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /home/www//wcc/score.php on line 15
this is line 15:
while($result = mysql_fetch_assoc($result)){
"...men are that they might have joy."
Nephi