|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now! |
|
#1
|
|||
|
|||
|
update table from another table
Hi,
I want to update a table with the contents of another table. All columns are the same in each table but there are a lot of them. What is the best way to do it. Do I have to specify each column name. Cheers. |
|
#2
|
|||
|
|||
|
update t1
set col2 = t2.col2 from table1 t1 inner join table2 t2 on t1.col1=t1.col2 where Col3 >5 just replace table1 with your tablename and col1 with your columnname |
|
#3
|
|||
|
|||
|
Thanks!
I didn't ask the question, but this code was exactly what I needed to come across. Thanks!!
|
![]() |
| Viewing: Dev Shed Forums > Databases > MS SQL Development > update table from another table |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|