Welcome Guest, Not a member yet? Register   Sign In
Mysql DB move 1 column (w/ data) from one table to another seamlessly?
#7

[eluser]Crafter[/eluser]
Code:
CREATE TEMPORARY TABLE temp
        (select t2.field2, t2.field3
         from table2 t2
         where t2.field3="somevalue");

      update table1 t1, temp t
      set t1.field3=t.field3
      where t1.field2=t.field2;


Messages In This Thread
Mysql DB move 1 column (w/ data) from one table to another seamlessly? - by El Forum - 09-18-2008, 12:19 AM



Theme © iAndrew 2016 - Forum software by © MyBB