Return to Snippet

Revision: 21982
at December 28, 2009 03:30 by choasis


Initial Code
INSERT INTO [TABLE2] AS T2 (NOLOCK) (T2.[VAL1], T2.[VAL2], ...)
SELECT T1.[VAL1], T1.[VAL2], ...
FROM [TABLE1] AS T1 (NOLOCK)
WHERE T1.[VAL1] = T2.[VAL1]

Initial URL


Initial Description
Just replace the squared brackets with the correct values.

Initial Title
Copy rows from one table to another

Initial Tags
copy

Initial Language
SQL