How we can copy one table data into another table whose name
same as table but in differ database

Answer Posted / guru

INSERT INTO database2.table_name (column_name)
SELECT table_name.column_name FROM table_name

If two databases are in same server, this code will work.
For more details visit,
http://www.phponwebsites.com/2013/12/Copy-values-from-one-database-to-another-in-mysql.html

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is table level locking in mysql?

654


Is there a free version of mysql?

638


How do you connect MySQL database with PHP?

707


How do I select a database in mysql workbench?

680


What is the date format in mysql?

634


What is datatype in mysql?

640


How can you calculate the sum of any column of a table?

691


What is a result set object?

710


What is mysql url?

641


Is mysql good for large database?

664


Is foreign key indexed mysql?

637


What are views in mysql?

678


Can you tell which of the following where clauses is faster?

626


How do I run a query in mysql?

687


How do I create a schema in mysql?

652