SQL TRUNCATE TABLE

The SQL TRUNCATE TABLE clause deletes all rows from a database table. Here is the SQL TRUNCATE TABKE syntax:

TRUNCATE TABLE Weather

The SQL TRUNCATE TABLE clause does the same as a SQL DELETE clause which doesn't have a SQL WHERE clause. The following two SQL statements are equivalent:

TRUNCATE TABLE Weather


DELETE FROM Weather

Use SQL TRUNCATE TABLE only when you want to delete all rows in a table.