What are the differences between drop a table and truncate
a table?

Answer Posted / shital

Delete - delete all the data from table but structure still remains as it is.
Truncate - delete all data from table but structure remains and memory still allocated for table.
Drop - delete all data as well as structure and also free the memory.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is mysql primary key?

594


Is null in mysql?

533


what is the difference between gui testing and database testing? : Mysql dba

585


What is cast in mysql?

556


What do ddl, dml, and dcl stand for?

552






How can you handle the –secure-file-priv in mysql?

589


What is the use of mysql_close()?

587


In how many ways we can retrieve data in the result set of mysql using php?

692


How do I rename a table in mysql?

591


Why do we use the mysql database server?

608


What is difference between mysql and mysql workbench?

543


What is mysql vs sql?

579


How do I select a table in mysql?

579


How many TRIGGERS are allowed in MySql table?

652


How to change the database engine in mysql?

528