Home > Backend Development > PHP Tutorial > 这条SQL语句究竟错在哪里?解决方案

这条SQL语句究竟错在哪里?解决方案

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 10:25:33
Original
956 people have browsed it

这条SQL语句究竟错在哪里??

SQL code
<!--Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->SELECT *FROM `offcn_c_all2012`WHERE (`type` LIKE '机关')OR ((`zhuanye` LIKE '%社会学%')OR (`zhuanye` LIKE '%授法学或哲学学士学位%')OR (`zhuanye` LIKE '%社会工作%')OR (`zhuanye` LIKE '%授法学或哲学学士学位%')OR (`zhuanye` LIKE '%社会工作%')OR (`zhuanye` LIKE '%人口学%')OR (`zhuanye` LIKE '%家政学%')OR (`zhuanye` LIKE '%人类学%')OR (`zhuanye` LIKE '%女性学%'))OR ((`other` LIKE '机关')OR (`other` LIKE '%社会学%')OR (`other` LIKE '%授法学或哲学学士学位%')OR (`other` LIKE '%社会工作%')OR (`other` LIKE '%授法学或哲学学士学位%')OR (`other` LIKE '%社会工作%')OR (`other` LIKE '%人口学%')OR (`other` LIKE '%家政学%')OR (`other` LIKE '%人类学%')OR (`other` LIKE '%女性学%')) LIMIT 0 , 10
Copy after login

提示错误是 #1054 - Unknown column 'other' in 'where clause' 


想来想去,也找不出哪错了,另外数据库是有这些字段的



------解决方案--------------------
重新书写select语句的other,复制过来的东西有时候也不可靠。然后看看表结构看有没有空格什么的或者哪个字符打错了。我上次复制的insert语句还说有问题。仔细检查检查吧。
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
Django's LIKE operation.
From 1970-01-01 08:00:00
0
0
0
Isn’t this iQiyi-like course finished? ?
From 1970-01-01 08:00:00
0
0
0
javascript - js cannot retrieve objects like this
From 1970-01-01 08:00:00
0
0
0
Why should I write it like this?
From 1970-01-01 08:00:00
0
0
0
How to open a developer tool like yours
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template