Collections:
Deleting All Rows in a Table in MySQL
How To Delete All Rows in a Table in MySQL?
✍: FYIcenter.com
If you want to delete all rows from a table, you have two options:
The TRUNCATE statement is more efficient the DELETE statement. The tutorial exercise shows you a good example of TRUNCATE statement:
mysql> SELECT COUNT(*) FROM fyi_links; +----------+ | COUNT(*) | +----------+ | 5 | +----------+ 1 row in set (0.08 sec) mysql> TRUNCATE TABLE fyi_links; Query OK, 0 rows affected (0.02 sec) mysql> SELECT COUNT(*) FROM fyi_links; +----------+ | COUNT(*) | +----------+ | 0 | +----------+ 1 row in set (0.00 sec)
⇒ SELECT Query Statements with GROUP BY in MySQL
⇐ Deleting Multiple Rows from a Table in MySQL
2018-01-08, 2469🔥, 0💬
Popular Posts:
How To Start MySQL Server in MySQL? If you want to start the MySQL server, you can run the "mysqld" ...
How To Use SQL*Plus Built-in Timers in Oracle? If you don't have a stopwatch/timer and want to measu...
How To Set Up SQL*Plus Output Format in Oracle? If you want to practice SQL statements with SQL*Plus...
How To View Data Files in the Current Database in Oracle? If you want to get a list of all tablespac...
Where to find SQL Server database server tutorials? Here is a collection of tutorials, tips and FAQs...