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.
| Author |
Topic |
|
satish.gorijala
Posting Yak Master
182 Posts |
Posted - 2009-04-01 : 09:57:12
|
| I have one table contains more than 50 columnscol1 col2............col60501 abc............def502 hjg............tyty678 hjk............iukl456 juy............lkjnow i have another table with 2 columnscol1 col2501 172678 345My requirement is, i want to insert new record in first table as based on second table...For example, from second table, i will retive data row 501 172. Now i have to insert in first table for record 172 with all 501 data.col1 col2............col60501 abc............def502 hjg............tyty678 hjk............iukl456 juy............lkj172 abc.............def345 hjk............iuklG. Satish |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2009-04-01 : 10:03:25
|
| See if you get required result though I am not sure if the table1 is normalisedselect t2.col2,t1.col2,t1.col3.....t1.col60 from table1 as t1 inner join table2 as t2on t1.col1=t2.col1MadhivananFailing to plan is Planning to fail |
 |
|
|
|
|
|