I have access to one database server through a vpn connection and another through lan connection.
from my machine I would like to copy some entries from one table into the other, like:
insert into destinationtable select * from sourcetable@databaselink where id in ('id1','id2','id3')
Establishing a database link does not work because the servers cannot see each other. Is there any other way to do it?
Install a database on your desktop, create links to both databases, and change the statement to something like this:
insert into destinationtable@databaselink_destination
select * from sourcetable@databaselink_source where id in ('id1','id2','id3')
You may need a virtual machine to bridge the networks. Set the host to one network and set the guest to another, and configure the VM to use both connections.
Depending on your exact configuration you may have additional issues, like licensing, OS privileges, etc. But I've found there is almost always a way to workaround those limitations.