Home > Backend Development > PHP Tutorial > SQL语句问题

SQL语句问题

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-20 12:27:26
Original
887 people have browsed it

select id from table where content like '%aa%'content是保存编辑器里的内容如何在搜索的时候排除标签的里关键字如 <img  src="/static/imghw/default1.png"  data-src=" aa.png"  class="lazy"   alt="SQL语句问题" >  在搜aa的时候不被搜出
Copy after login


回复讨论(解决方案)

SQL 不具备这个能力

//不知道是否符合你要求,试下select id from table where content like '%aa%'  and content not regexp '.*aa.*\\.[jpg|png|jpeg]';
Copy after login

Related labels:
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template