I'm currently using the following code to select and get info from the database:
(I am using mysql 5 and php 5)
Now on the page it displays:
This is really weird because I have never had such issue before. I have another script using almost identical code and it's working fine.
Any help is much appreciated
(I am using mysql 5 and php 5)
PHP:
$result = mysql_query("SELECT * FROM order WHERE status='pending'") or die(mysql_error());
while($row = mysql_fetch_array( $result )) {
<outputs the data here>
}
Now on the page it displays:
Code:
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 'order WHERE status='pending'' at line 1
This is really weird because I have never had such issue before. I have another script using almost identical code and it's working fine.
Any help is much appreciated




