Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 update 2 columns

Author  Topic 

peace
Constraint Violating Yak Guru

420 Posts

Posted - 2014-06-23 : 21:40:16
I have a list of long data.

How can I update column1 to column2?

column1 column2
123 32432
234 98798
345 43254
456 09709
567 456756
678 8768
789 765
'
'
'
'
'
'

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2014-06-24 : 04:09:48
update table
set column1 = column2

In the result you have a table where column1 and column2 are equal.
Is that what you want?


Too old to Rock'n'Roll too young to die.
Go to Top of Page
   

- Advertisement -