> I have a slew of records that went to the wrong database.  The tables
>  have the same names and now I want to copy those records over to the
>  correct database.  Is there such a mechanism using the cli mysql
>  application in Linux?

If the tables have the same schema, you should be able to just do a
mysql dump and pipe that back into itself.  Something along the lines
of:

mysqldump <old_table> | mysql <new_table>

But that will only work if the tables have the same structure.  If
they don't, you can work with variations of the above.

[JS] I think he wants to bring over only certain records. In that case he
can use "INSERT INTO ... SELECT ...",
Where the INSERT INTO references the table in one database and the SELECT
references the table in the other database.

thnx,
Chris

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to