I get an ORA-02291: integrity constraint violated - parent key not found. It looks like OpenJPA is trying to insert the parent entity before inserting the children. This only happens to me when using an Oracle Database and when the children are new entities (the update works fine). I've reproduced the issue in a simple testcase (see attachment) using open-jpa-all jar in a JavaSE environment, but I've also tested it using TomEE in a JavaEE environment.
I'm still a little skeptical that such an issue could have gone unnoticed for such a long time, so I'm pretty sure I am doing something wrong here. If that's the case please forgive me for opening this issue, but I'm out of ideas and this is causing me some serious head ache.
This message was sent by Atlassian JIRA