As I understand it, when you update one or more rows in SQL Server, the record is deleted and reinserted with the new values. Does this therefore mean that an INSERT event is triggered, or just an UPDATE when rows are updated?
EDIT: To highlight the main info for any lazy readers (although I recommend that you read the full link details in davek 's answer below):
Does SQL do all updates as split updates?
Short answer is:
NO
Slight longer answer:
For updates that change the key values, SQL will not do those as in-place updates.
I think that (the split into delete + insert) is only true when the update requires the index to be updated. See this link:
http://www.sqlservercentral.com/blogs/sqlinthewild/2011/06/21/are-all-updates-split-into-delete_2D00_insert_3F00_/
and particularly the last paragraph:
An update never triggers an insert event even if physically it is implemented as an insert/delete as logically the operation is still an
UPDATE
.There is a phrase in the accepted answer that is not quite true if taken to be talking about logical updates of the key column.
This is not the case for a multirow update against a unique index. For those SQL Server gives a plan with split/sort/collapse operators. So in the following example the 9 update operations get converted to 1 delete, 8 updates, and an insert.
Returns