Welcome to WebmasterWorld Guest from

Forum Moderators: open

Message Too Old, No Replies

MySQL Trigger to populate An Oracle table

How to create a Mysql trigger that can populate an oracle table on a server

11:03 am on Mar 13, 2012 (gmt 0)

Full Member

10+ Year Member

joined:Dec 12, 2007
votes: 0

Hi all,
I have a problem of how to create or find an automated script that can select daily inserts from a mysql table and then put the selected data in an other table on an Oracle database. Can someone help here?

I'll be very greatful for your help because the database is in a production and users of it are becoming impatient.
9:35 pm on Mar 13, 2012 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:May 31, 2005
votes: 0

First you probably want to establish a ODBC Gateway between MYSQL and the Oracle DB.
This will allow you to select from MySQL and insert into Oracle in one SQL statement.
You can then have a cron job execute MySQL statements.

(Search on the bolded phrases if you need to find more details).

You will then either want a flag or a inserted/date time on your MySQl database table so you can select the records that you want to insert into Oracle. My preference would be a flag as the date/time method would involve date comparisons to the last run of the script.
12:44 pm on Mar 15, 2012 (gmt 0)

New User

5+ Year Member

joined:Mar 15, 2012
votes: 0

You may want to explore Tungsten Replicator for this task.
Please see [tungsten-replicator.org...] for the tool itself.
There is an explanatory article at [flyingclusters.blogspot.com...]