Home > Archive > PHP DB > November 2006 > Transfer data between tables in MySQL
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Transfer data between tables in MySQL
|
|
|
| Hi,
I have to transfer all data between two tables ( with identical structure )
Is this possible with one query, or I must read from table1 and manually
insert into table2?
Thanks in advance,
Rosen
| |
| benmoreassynt 2006-11-29, 9:57 pm |
| Rosen wrote:
> Hi,
> I have to transfer all data between two tables ( with identical structure
> ) Is this possible with one query, or I must read from table1 and manually
> insert into table2?
>
> Thanks in advance,
> Rosen
INSERT INTO `dbase2`.`table1`
SELECT *
FROM `dbase1`.`table1` ;
That will copy from 1st database to second. If you use phpMyAdmin you can do
it via the "operations" tab.
BMA
|
|
|
|
|