What is difference between TRUNCATE and DELETE statement
Answer Posted / archana motagi
Both the operations can be rolled back.The difference is,
DELETE TABLE is a logged operation, so the deletion of each
row gets
logged in the transaction log, which makes it slow.
TRUNCATE TABLE
also deletes all the rows in a table, but it won't log the
deletion of
each row, instead it logs the deallocation of the data
pages of the
table, which makes it faster.
| Is This Answer Correct ? | 17 Yes | 4 No |
Post New Answer View All Answers
How to list all columns in a table using odbc_columns()?
Explain forward - only cursors?
How to count rows with the count(*) function in ms sql server?
What is data modification?
What specific conditions database should meet, before you can bulk copy data into it using bcp?
What is indexed view? How to create it?
Explain the relational database management system (rdbms)?
what are the different types of SSRS reports?
When I run the sql server 2000 setup, it just hangs. What do I do?
How will you decide the active and passive nodes?
What is index, cluster index and nonclustered index?
How to list all field names in the result set using mssql_field_name()?
what is a self join? Explain it with an example? : Sql server database administration
What are sql servers used for?
What are the differences between having and where clause.