What is the difference between the DELETE TABLE and TRUNCATE TABLE commands in MySQL?
Answer Posted / hrindows@gmail.com
DELETE TABLE is a logged operation, and every row deleted is logged. Therefore, the process is usually slow.
TRUNCATE TABLE also deletes rows in a table, but it will not log any of the rows deleted. The process is faster here in comparison. TRUNCATE TABLE can be rolled back and is functionally similar to the DELETE statement without a WHERE clause.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Explain the difference between mysql and mysql interfaces in php?
How do I restart mysql on windows?
What is field in mysql?
What do I do if I forgot my mysql root password?
What is mysql primary key?
What is trigger in mysql?
What is localhost in mysql?
Where is the mysql data directory?
Does mysql scale well?
What is max connection in mysql?
If we use sum function in mysql, does it return sum of that row or for that column?
How do I kill a mysql query?
Is foreign key indexed mysql?
What is mysql in dbms?
What are the limitations of mysql?