It is very easy to delete a table in MySQL, but you must be very careful when doing so, because all data will disappear after the deletion command is executed. grammar The following is the general syntax for deleting a MySQL table: DROP TABLE table_name ; Deleting a table in the command prompt window In the mysql> command prompt window, the SQL statement to delete the data table is DROP TABLE Method extension: There are two ways to delete data in MySQL, one is the DELETE statement and the other is the TRUNCATE TABLE statement. The DELETE statement can select the records to be deleted through WHERE. Using TRUNCATE TABLE will delete all records in the table. Therefore, the DELETE statement is more flexible.
The TABLE in the second record is optional. If you want to delete some records in a table, you can only use the DELETE statement. DELETE FROM table1 WHERE ...; This is the end of this article about how to delete MySQL data tables. For more information about simple methods to delete MySQL data tables, please search for previous articles on 123WORDPRESS.COM or continue to browse the following related articles. I hope you will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: 4 ways to view processes in LINUX (summary)
>>: Detailed explanation of keepAlive use cases in Vue
CentOS7 is used here, and the kernel version is [...
The Golden Rule Always follow the same set of cod...
Tip: In MySQL, we often need to create and delete...
Abstract: HBase comes with many operation and mai...
There are many database management tools for MySQ...
MySQL installation is divided into installation v...
Step 1: Get the MySQL YUM source Go to the MySQL ...
Table of contents Overview Object rest attribute ...
This article mainly introduces the installation/st...
1. Install ffmpeg under centos linux 1. Download ...
In order to enhance the ability to write JavaScri...
Table of contents 1. Lock and Latch 2. Repeatable...
Table of contents Preface background Big guess Fi...
Win10 system locally installed MySQL8.0.20, perso...
Table of contents Vue.js 1. Register global guard...