I want to push some values from one database (DB1) from a host (HOST1) to another database (DB2) from another host (HOST2). The query structure should be like following.
insert into HOST2.DB2.TABLEA (COL1, COL2, COL3)
select COL1, COL2, COL3 HOST1.DB1.TABLEB ..
I know this will work with two different dbs in a same host. But dont know about two different hosts.
I am using java to perform this action.
Thanks in advance.
mysqldump. One could export to a csv file but then has to copy that file too. So a java program seems simplest - if the databases are open to the net. Maybe there are admin sql "console" sites.