FB wrote:
Hi,

I have 3 similar tables. I want to merge them. The thing I use is

1) SELECT *
2) Make a while statement
3) INSERT each raw into the other table

is there a easier way?

FB

if the columsn are identical


insert into table1 select * from table2;
insert into table1 select * from table3;

if the column names are different

insert into table12 (colname1, calname2) select colname3, colname4 from walks;

the above works on mysql ...

--

Sean


-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to