Jio Interview Question

difference between delete and truncate ? basic database questions

Interview Answers

Anonymous

Dec 18, 2017

delete:delete row or table but can not free up space.dml command.rolled back. trucate:delete table and also free up the space.ddl command..not rolled back.

Anonymous

Dec 24, 2017

Delete command will delete whole data from the table and table as well,after that there is no existence of table (table is deleted permanently ). Truncate command will delete the data in the table but the structure of the table will remain,at any point of time we can use that structure.(structure of table will remain in the memory).used in testing purpose.