Question:
Notice: Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL Server?
2014-01-11 06:45:14 UTC
Please Help its very urgent to me :(
i m working on opencart ecommerce soft i installed some new module for the website when i uploaded the files it was all clean installation but when i try to add something from admin panel i m getting this error
in my phpmyadmin i uploaded these 2 files oc_state.sql & oc_state_city.sql


Notice: 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 'state_city where city_code='400078'' at line 1
Error No: 1064
select state_id,city_name,area_name,city_code fromoc_ state_city where city_code='400078' in /home/demostore/public_html/oc/system/database/mysql.php on line 50
Three answers:
Serge M
2014-01-11 08:00:58 UTC
Try this



select state_id, city_name, area_name, city_code from oc_state_city where city_code='400078';
Sunil
2014-01-11 08:28:13 UTC
Missing "," between "city_code fromoc_ state_city"



Your query :

select state_id,city_name,area_name,city_code fromoc_ state_city where city_code='400078'



Currect query:

select state_id, city_name, area_name, city_code, fromoc_ state_city where city_code='400078';



Good luck!!
Shubhradeep M
2014-01-13 13:01:30 UTC
You are missing a space between "from" and the table name "oc_ state_city". This should work


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...