MySQL Database
The DROP TABLE statement is used to drop an existing table in a database.
DROP TABLE table_name;
Note: Exercise caution when lowering a table. All of the data contained in a table will be lost if it is deleted!
The following SQL statement drops the existing table “Shippers”:
DROP TABLE Shippers;
A table’s contents can be removed using the TRUNCATE TABLE statement, but the table itself cannot be removed.
TRUNCATE TABLE table_name;
CodingAsk.com is designed for learning and practice. Examples may be made simpler to aid understanding. Tutorials, references, and examples are regularly checked for mistakes, but we cannot guarantee complete accuracy. By using CodingAsk.com, you agree to our terms of use, cookie, and privacy policy.
Copyright 2010-2024 by Refsnes Data. All Rights Reserved.