copy data between databases

Questions and answers regarding general SQL and backend databases

copy data between databases

Postby Hans Nieuwenhuis » Fri Jun 14, 2013 1:22 pm

Hi,

I am looking at copying data between Oracle and postgres database.
This is not for migration, but to get some data from the other database and use that.
Will be done once a day or so.

I am thinking about a headless client.

But what is the best way to actually copy the data ?
- copy foundsets
- copy datasets
- copy records

Regards,
Hans Nieuwenhuis
Betagraphics
http://www.deltics.nl
http://www.betagraphics.nl

Servoy Version 7.3.1
Java version 1.7.0.x
Database Oracle 11g
User avatar
Hans Nieuwenhuis
 
Posts: 1026
Joined: Thu Apr 12, 2007 12:36 pm
Location: Hengelo, The Netherlands

Re: copy data between databases

Postby david » Fri Jun 14, 2013 8:01 pm

Creating records in mass with Servoy is not fast. If you must, this technique is the way to go: http://www.servoymagazine.com/home/2013 ... lugin.html.

Better to grab your data via dataset or foundset and write out your own sql file of insert statements. Can load PostgreSQL using this file with the sql plugin or triggering a command line app.

Another option is to replicate Oracle to PostgreSQL. A few tools out there for this.

If you don't have a lot of records, then creating records through foundset has one gotcha: reset the destination foundset to empty every several hundred records or so. Creating records in foundsets gets slower as the foundset gets bigger.
David Workman, Kabootit

Image
Everything you need to build great apps with Servoy
User avatar
david
 
Posts: 1727
Joined: Thu Apr 24, 2003 4:18 pm
Location: Washington, D.C.


Return to SQL Databases

Who is online

Users browsing this forum: No registered users and 7 guests