I need to create new table and, after that, copy some columns of some table into the new table. Three columns from the first table. Five columns from the second table. Three columns from the third table. Three columns from the fourth table.
The columns from table one: eid(primary key),first name,last name,status.
The columns from table two: mid(primary key), sender, subject,body,folder.
The columns from table three: rid(primary key) , mid ,rvalue.
The columns from table four: rfid(primary key), mid, reference.
How can I do this?
INSERT INTO newtable(...) SELECT whatever from the old tables. How do You recognize corresponding rows in the "old" tables?