Hi. I have been having problems with a mysql query. It comes up with errors saying that it is not a valid result resource. Here is my query:
PHP Code:
function get_dives($no_start$limit$order$direction$userid){
     
$no_start $no_start 1;
     if(
$limit == "")
      
$limit == "";
      else
      
$limit " LIMIT 0, $limit";
      
     
$dives mysql_query("SELECT `diveno`, UNIX_TIMESTAMP(date) as date,`purpose` ... FROM dives WHERE `diveno` > $no_start && `userid` = '$userid' ORDER BY `$order` '$direction' '$limit'");
... 

Any ideas??? I am probably doing something obviously wrong that i can't see... thanks