# Help with this query?

**URL:** <https://forum.kirupa.com/t/help-with-this-query/204473>\
**Category:** Uncategorized\
**Created:** [October 20, 2006, 12:57am UTC](https://forum.kirupa.com/t/help-with-this-query/204473 "2006-10-20T00:57:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Flash\_Man1](https://avatars.discourse-cdn.com/v4/letter/f/8797f3/32.png) [@Flash\_Man1](https://forum.kirupa.com/u/Flash_Man1)\
**Post date:** [October 20, 2006, 12:57am UTC](https://forum.kirupa.com/t/help-with-this-query/204473/1 "2006-10-20T00:57:43Z")

</div>

```auto
$query = "SELECT * FROM leaderboard ORDER BY score DESC LIMIT 10";
$result = mysql_query($my_query);
$num = @mysql_num_rows( $result );
$i = 1;

while($line = @mysql_fetch_array($result)){
$name[$i] = $line['name'];
$score[$i] = $line['score'];
$i++;
}
for ($i=1; $i<=$num;$i++){
$text = $results . "&name$i=" . $name[$i] . "&score$i=" . $score[$i];
}
echo $text;
//print (mysql_error());

?>

```

when i test this query in mysql itself i get the results i am aiming for :D…YET when i test the script from the browser or through flash i get this error:

“query empty” why?? or what does this mean?

cheers peeps
