Home » RDBMS Server » Networking and Gateways » Insert record to non-Oracle database from Trigger
Insert record to non-Oracle database from Trigger [message #66421] Tue, 04 June 2002 00:50 Go to next message
Marko Sirovnik
Messages: 1
Registered: June 2002
Junior Member
There are two databases Oracle 8i and IBM DB2 (Ver. 7.02). The goal is making almost on-line synchronisation between these two databases. If you have any suggestion how to this I will be greatly appreciated.

My approach and problem:

On Oracle side I made Oracle Generic Connectivity in order to link DB2 database to Oracle. I have used DB2 ODBC driver and Oracle Heterogeneous Services. I made this succesfully.

Then I have used the SQLPlus Worksheet tool and typed the INSERT SQL syntax in order to add new record to linked database (DB2). It was working:-)))

But the problem comes when I make a trigger on Oracle tabel (trigger AFTER INSERT) which triggers the INSERT SQL syntax to linked database. The INSERT syntax inside the trigger is totally the same as this one which I typed in SQLPlus Worksheet, but it doesn't work from the trigger. Why!?

The following errors are generated:
ERROR at line 1:
ORA-02047: cannot join the distributed transaction in progress
ORA-06512: at "FND.TRG_TEST", line 4
ORA-04088: error during execution of trigger 'FND.TRG_TEST'

Anyone knows what could be wrong?

Thanks and Regards,
Marko
Re: Insert record to non-Oracle database from Trigger [message #66669 is a reply to message #66421] Wed, 09 October 2002 23:10 Go to previous messageGo to next message
Charlotte J. Brandt
Messages: 1
Registered: October 2002
Junior Member
I found your question when I was looking for an answer to a similar problem.

I solved my problem by commiting the updates on the Oracle database before i started updating the non-Oracle database.

But I don't know if that is possible in a trigger.

Good luck!

Best regards,

Charlotte
Re: Insert record to non-Oracle database from Trigger [message #66825 is a reply to message #66421] Thu, 23 January 2003 05:44 Go to previous messageGo to next message
Manfred Lennartz
Messages: 1
Registered: January 2003
Junior Member
How did you implement the generic connectivity to access data from the db2-database into your oracle system? What ODBC-drivers are you using? I'm not able to connect to db2 from my oracle db-system. Could you please help me?
Re: Insert record to non-Oracle database from Trigger [message #67303 is a reply to message #66421] Thu, 15 April 2004 11:56 Go to previous messageGo to next message
Ludgardo Job
Messages: 1
Registered: April 2004
Junior Member
I have a similar problem.

After creating a link to the remote database, I have used the SQLPlus Worksheet tool and typed the INSERT SQL syntax in order to add new record to linked database (MS SQL). It is working.

But the problem comes when I make a trigger on Oracle tabel (trigger AFTER INSERT) which triggers the INSERT SQL syntax to linked database. The INSERT syntax inside the trigger is totally the same as this one which I typed in SQLPlus Worksheet, but it doesn't work from the trigger.

Did you got a fix or a workaround for this?
Re: Insert record to non-Oracle database from Trigger [message #67717 is a reply to message #66421] Mon, 24 January 2005 19:59 Go to previous message
andi
Messages: 23
Registered: March 2004
Junior Member
I have same problem for my trigger in Oracle DB that updates SQL DB :
ORA-02047: cannot join the distributed transaction in progress
Anybody can help ?
Previous Topic: Notify Java socket server from oracle trigger
Next Topic: connecting oracle 8i client to oracle 8i server
Goto Forum:
  


Current Time: Tue Apr 30 19:36:46 CDT 2024