Trigger for only updating specific column

  • sizal0234


    Points: 2194


    using Merge I can sync table A with Table B at ROW level. However 'how to update only specific column instead of the whole row'?



  • ScottPletcher

    SSC Guru

    Points: 98484

    In the WHEN MATCHED part of the MERGE, specify only the columns you want UPDATEd.

    SQL DBA,SQL Server MVP(07, 08, 09) Prosecutor James Blackburn, in closing argument in the Fatal Vision murders trial: "If in the future, you should cry a tear, cry one for them [the murder victims]. If in the future, you should say a prayer, say one for them. And if in the future, you should light a candle, light one for them."

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply