title: How to find columns get affected in sql server update statement
body: <p>I have a log table columns like below</p>
  
  <pre><code>   [Id]      
    ,[Attribute]
    ,[Action]
    ,[OldValue]
    ,[NEwValue]
    ,[UserId]
    ,[ModifiedDate]
  </code></pre>
  
  <p>where id is row id getting affected . attribute is the column being affected . Action is "insert " or "update' depending on na type of operation being performed . 
  In case of update old value and new value of the column being updated should be inserted  to newValue nad old Value columns in log table .</p>
  
  <p>Wat is the best possible way to achieve this. Should I go for triggers or stored procedure .?</p>