SQL Update From One Table To Another Based On a ID Match


Here is the command for SQL update column with value from another table


UPDATE
t1
SET
     t1.Column = t2.Column,
FROM
     TableOne t1
     INNER JOIN TableTwo t2
     ON t1.Column = t2.Column;
Go

Comments

Popular posts from this blog

The Power of .NET Core Caching: Best Practices for Optimal Performance

Custom Function string_split for SQL Server 2008R2 (T-SQL split string)

Find the number of columns in a table