unidox Posted May 29, 2008 Share Posted May 29, 2008 I have this: 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 ''pcp_users' WHERE 'user_id' = '69'' at line 1 This is the line of code: $table = $this->table; $table_id = $this->table_id; $q = mysql_query("SELECT * FROM '$table' WHERE '$table_id' = '69'") or die (mysql_error()); Whats wrong? Quote Link to comment Share on other sites More sharing options...
pocobueno1388 Posted May 29, 2008 Share Posted May 29, 2008 Try this: $query = "SELECT * FROM $table WHERE '$table_id' = 69"; $q = mysql_query($query) or die (mysql_error()."<p>With Query<br>$query"); That will show you the query, and you can make sure all the variables are properly filled in as well. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.