When to use negative identity

The identity value in relational databases is a field that increases automatically. It is often used to create surrogate primary keys. Surrogate keys Surrogate keys are meaningless and are only used to uniquely identify the row, not the data itself. For example, assume the following table: As we can see,

Use CONTEXT_INFO to avoid firing triggers

DML Triggers are commonly used to apply some business rules to the data in the table. The most common implementation would be updating the date_updated column automatically whenever the data in the table changes. For the illustration, this can be done with a following trigger: However, there are times where