Home >Database >Mysql Tutorial >How to write the delete statement in mysql database

How to write the delete statement in mysql database

王林
王林Original
2020-05-08 14:25:465991browse

How to write the delete statement in mysql database

Syntax of delete statement:

DELETE FROM table_name [WHERE Clause]

Example:

Delete the record with id 3 in the tbl table

mysql> use TB;
Database changed
mysql> DELETE FROM tbl WHERE id=3;
Query OK, 1 row affected (0.23 sec)

Recommended tutorial: mysql tutorial

The above is the detailed content of How to write the delete statement in mysql database. For more information, please follow other related articles on the PHP Chinese website!

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