delete and truncate operation | SQL Server Performance Forums

SQL Server Performance Forum – Threads Archive

delete and truncate operation

Can some one point out the differences between delete and truncate operation performed on tables.
See this:http://www.sql-server-performance.com/q&a118.asp
Frank Kalis
Microsoft SQL Server MVP
http://www.insidesql.de
Ich unterstütze PASS Deutschland e.V. http://www.sqlpass.de)

delete on records (space still retained )
Truncate on table (space wil be freed, only table structure will be retained )

delete is logged operation while truncate is not logged operation hsGoswami
[email protected]
"Humans don’t have Caliber to PASS TIME , Time it self Pass or Fail Humans" – by Hemant Goswami

It is a common mistake to think, TRUNCATE is non-logged. The deallocation of the data pages IS logged. BOL in it’s January 2004 version mentions this. Maybe you should update to that version. [<img src=’/community/emoticons/emotion-1.gif’ alt=’:)‘ />]<br /><br />–<br />Frank Kalis<br />Microsoft SQL Server MVP<br /<a target="_blank" href=http://www.insidesql.de>http://www.insidesql.de</a><br />Ich unterstütze PASS Deutschland e.V. <a target="_blank" href=http://www.sqlpass.de>http://www.sqlpass.de</a>) <br />
thanks Frank will sure download and update to new BOL…. Regards. hsGoswami
[email protected]
"Humans don’t have Caliber to PASS TIME , Time it self Pass or Fail Humans" – by Hemant Goswami

Yes and you should always update the books online in every service pack release of SQL server. Satya SKJ
Moderator
http://www.SQL-Server-Performance.Com/forum
This posting is provided “AS IS” with no rights for the sake of knowledge sharing.
]]>