sql server - How to update a table from the same table in the backup? -


i want recover values table. want use table backup. how update table same table in backup?

this source

update dbcurrent.dbo.table1 curr  set curr.value1 =   (select bck.value1    dbbackup.dbo.table1 bck    bck.id = curr.id    , bck.id2 = curr.id2 ) 

how do that?

may work fine

update curr   set curr.value1 =  bck.value1  value1 curr   inner join value1 bck   on bck.id = curr.id  , bck.id2 = curr.id2 

Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -