GoldenGate, Streams and Distributed Database (MOSC)

MOSC Banner

Dbms_transaction.PURGE_LOST_DB_ENTRY - ORA-01453: SET TRANSACTION must be first statement of transac

edited Feb 25, 2020 4:36PM in GoldenGate, Streams and Distributed Database (MOSC) 8 commentsAnswered ✓

Hi, I have zombie 2pc transactions, I tryed to clean the istance using:

BEGIN

     FOR REC_CUR IN (SELECT * FROM SYS.dba_2pc_pending) LOOP

          Dbms_transaction.PURGE_LOST_DB_ENTRY (REC_CUR.LOCAL_TRAN_ID);

     END LOOP;

END;

/

But I got this error:

ERROR at line 1:

ORA-01453: SET TRANSACTION must be first statement of transaction

ORA-06512: at "SYS.DBMS_TRANSACTION", line 74

ORA-06512: at "SYS.DBMS_TRANSACTION", line 96

ORA-06512: at line 4

On MOS i've found Manually Resolving In-Doubt Transactions: Different Scenarios (Doc ID 126069.1)

Where is wrote this:

** NOTE1: If using Oracle 9i or later and DBMS_TRANSACTION.PURGE_LOST_DB_ENTRY fails with

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center