Home >Database >Mysql Tutorial >MYSQL删除表中的指定ID数据

MYSQL删除表中的指定ID数据

WBOY
WBOYOriginal
2016-06-07 17:55:171436browse

有些时候我们需要删除表中指定ID数据,主要是接下模糊删除,需要的朋友可以参考下

删除A表中的ID 中的开头以B* 的数据库。
代码如下:
delete FROM A WHERE id like 'B%'

单独删除 A 表中的ID B
代码如下:
delete FROM A WHERE id = 'B'
Statement:
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