Re: INSERT SELECT and VALUES

2002-07-18 Thread Egor Egorov
Simon, Thursday, July 18, 2002, 1:21:20 PM, you wrote: >> I am trying to copy data from one table to another using in MySQL >> INSERT INTO table1 >> SELECT table2 >> statment but I would like to add some fixed values to this and so some >> thing like. >> INSERT INTO table1 >> SELECT table2 >> VA

Re: INSERT SELECT and VALUES

2002-07-18 Thread Arul
Hi SImon Try this INSERT INTO table1 SELECT 12 as fixedvalue1 , 20 as fixedvalue2 ,table2.A , table2.B FROM table2 WHERE table2.id = 10 First the SELECT Query is executed from the table 2 which has id = 10 The Result would be somethin

Re: INSERT ... SELECT and VALUES? Is this possible?

2001-10-31 Thread Paul DuBois
At 4:51 PM -0700 10/31/01, Nathan wrote: >I have a table(2) with a different structure than the table(1) I'm >selecting from. I want to be able >to grab some info from table1, put it in table2, along with some >variables from my php page. Is it >possible to do like: > >INSERT INTO table2 VALUES