RowInconsistentException JBO-25014: Another user has changed the row with primary key

By W.ZH, Sept 2011

Issue: 

When I develop the ADF BC code, I got this error “JBO-25014: Another user has changed the row with primary key [222]”. My project is based on the 11.1.1.4 release, both Jdev and Weblogic server.

Reason:

The issue normally is caused by the data merge conlict to one EO, often when ur code is very complex. Read these chapters in the adf dev guide will help u understand it more.

Related Chapter in the ADF developer guide

4.10.11 How to Protect Against Losing Simultaneously Updated Data

40.11.1 How to Set Applications to Use Optimistic Locking

Solution:

You should notice that this kind of error, key[222]. 222 is the primary key for you conflict object cause the DB transaction commit error. By this, you can know which table/EO/VO cause the issue. (Just because in one transaction, you normally will change and read many VO/EO/table data.).

So get your Enitiy Object define and find out whiich filed is used as the change indictor in the EO, Normarlly we use the “Updated On” timestamp as the change indictor for the EO. So you can check the check box of Refresh After Insert and Refresh After Update options in the Edit Attribute dialog. Then try again. This mostly can solve this issue.

Refer links:

http://cn.forums.oracle.com/forums/thread.jspa?messageID=7440027

Advertisements