insert into 表1 (t1_fild1,t1_fild2,t1_fild3,t1_fild4)
 select t2_fild1,t2_fild2,v3,v4 from 表2

解决方案 »

  1.   

    谢谢tj_dns(愉快的登山者)!v3,v4不是表2的字段,也可以这样写,我倒是把他搞复杂了。
      

  2.   

    insert into 表1 (t1_fild1,t1_fild2)
     select t2_fild1+@v3,t2_fild2+@v4 from 表2
      

  3.   

    liying1212(过客):
    我是想把v3,v4分别加在t1_fild3,t1_fild4字段中。
      

  4.   

    那就是 tj_dns(愉快的登山者) 的方法。
    insert into 表1 (t1_fild1,t1_fild2,t1_fild3,t1_fild4)
     select t2_fild1,t2_fild2,v3,v4 from 表2
      

  5.   

    insert 表1 select *,v3,v4 from 表2