This question already has an answer here:
I have tried these SQL querys:
$sql = "SELECT * FROM `order` WHERE `KLANT_ID` = \'1\'";
$sql = "SELECT * FROM order WHERE KLANT_ID = '1'";
$sql = "SELECT * FROM order WHERE KLANT_ID = 1";
If i run these i get this error :
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 KLANT_ID='1'' at line 1
I normally did this query with 1 being a variable $id but that gave the same error. Also deleting `` these from order and KLANT_ID does not work.
Also when i change this part : \'1\'
to '1' it does not work
This is al done with PHP MYSQLI and PHPMYADMIN database
Thank you
</div>