• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Connection between two databases

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I am using two databases.My database is DB2 So in my java code I make a connection1 for SAMPLE1. Now connection is made specifying the Database name..so its db1 in this case.

Now for second database SAMPLE2 i am using another connection2. After making successful connections I want to pass data between two database. So I want to fetch data from DB sample1 with "select * from emp" and insert this into another DB sample2's emp table with insert query. I am doing this in java.

If it had been same database we could have used "Insert into emp select * from emp" but as these are two different DBs and two different connections its difficult to communicate.

Does anyone know if there we can use some common driver/connection object between two different DBs ? Or is there any other way to manipulate between two databases using a common or combined connection object ?

 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Maybe something like this: http://sourceforge.net/projects/dbtamer/ ?

Generally, the search term you're looking for is "JDBC ETL tool" (for Extract, Transform, Load).
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hmm, where have i heard of that before...
I need to get back to that soon. So much uncommitted code!
 
Time is mother nature's way of keeping everything from happening at once. And this is a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic