What is the error of this SQL statement ?? SQLcodeSELECT * FROM 'offcn _ c_all2012 'WHERE ('type' LIKE 'authorization') OR ('zhuanye' LIKE '% sociology % ') OR ('zhuanye 'like' % where is the error of this SQL statement taught by law OR philosophy ??
SQL code
SELECT * FROM 'offcn _ c_all2012 'WHERE ('type' LIKE 'authorization') OR ('zhuanye' LIKE' % % ') OR ('zhuanye 'like' % bachelor's degree in law OR philosophy %') OR ('zhuanye 'like' % social work % ') OR ('zhuanye 'like' % bachelor's degree in law OR philosophy %') OR ('zhuanye 'like' % social work % ') OR ('zhuanye 'LIKE' % demographic % ') OR ('zhuanye' LIKE '% Political science %') OR ('zhuanye 'LIKE' % anthropology % ') OR ('zhuanye 'LIKE' % Female % ') OR ('Other' LIKE 'authorization') OR ('Other' LIKE' % sociology % ') OR ('Other' LIKE '% bachelor's degree in law OR philosophy %') OR ('Other' LIKE '% social work % ') OR ('Other' LIKE '% bachelor's degree in law OR philosophy %') OR ('Other' LIKE '% social work % ') OR ('Other' LIKE '% demographic %') OR ('Other' LIKE '% Political science %') OR ('Other' LIKE '% anthropology % ') OR ('Other' LIKE '% Female %') LIMIT 0, 10
The error message is: #1054-Unknown column 'other' in 'where clause'
I can't find any errors. In addition, the database has these fields.
------ Solution --------------------
Re-writing the other of the select statement is sometimes unreliable. Then, check the table structure to see if there are any spaces or which character is wrong. The insert statement I copied last time also says there is a problem. Check carefully.