Jump to content

[SOLVED] INCORRECT SQL


PC Nerd

Recommended Posts

hi guys

 

im having trouble with the following SQL, the error i receive is:

 

Query died: 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 '=< 20 ORDER BY Rank, User_Name' at line 1

 

CODE

 

$lower_page_num = $start_page * 20;
$higher_page_num = ($start_page + 1) * 20;

$curr_page_SQL = "SELECT User_Name, Points, Rank, Resource_1 FROM General_Stats WHERE Rank >= ".$lower_page_num." AND =< ".$higher_page_num." ORDER BY Rank, User_Name";


$curr_page_query = mysqli_query($DB_Server, $curr_page_SQL) or die("Query died: ".mysqli_error($DB_Server));

 

thanks for any help

 

PC Nerd

Link to comment
Share on other sites

still the error:

 

Query died: 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 '<= 20 ORDER BY Rank, User_Name' at line 1

 

thanx anywayz, anything else i should try

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.