Avadhesh Kumar Patel District Project Manager - Aligarh 14 months work experience in Panchayati Raj Department Sector as District Project Manager & 12 months work experience in IT Sector as Software Engineer. :-)
Both, perform the Operation of getting rid of rows in the Specified Table. But differs in the perspective of State,
When you issue Delete command for deleting Specific records in Table, Ignoringly you have deleted the wrong
set of records, then the Transaction can be rolled back, which simply implies that DELETE statements or DML operation can be roll backed to previous state.
Ex : When you issue a delete statement which has a corresponding BEGIN TRANSACTION, Suppose the user disconnects then the Transaction is rollbacked.
Where as when considering DDL Statements they cannot be roll backed, Simply you might think of DDL statements as Auto commit.
TRUNCATE is a DDL command whereas DELETE is a DML command. DELETE operation can be rolled back, but TRUNCATE operation cannot be rolled back. WHERE clause can be used with DELETE and not with TRUNCATE.
Liked By
Write Answer
Difference between TRUNCATE and DELETE commands?
Join MindStick Community
You have need login or register for voting of answers or question.
Shankar M
23-Feb-2013AVADHESH PATEL
21-Jan-2013DELETE operation can be rolled back, but TRUNCATE operation cannot be rolled back.
WHERE clause can be used with DELETE and not with TRUNCATE.