Description
Exception is thrown when retrieving an entity which contains an embeddable and the embeddable contains a toMany relation. This happens when QuerySQLCache is on.
Caused by: java.lang.ArrayIndexOutOfBoundsException: Array index out of range: -1
at org.apache.openjpa.util.ApplicationIds.toPKValues(ApplicationIds.java:83)
at org.apache.openjpa.jdbc.sql.SelectImpl.wherePrimaryKey(SelectImpl.java:1444)
at org.apache.openjpa.jdbc.meta.strats.StoreCollectionFieldStrategy.load(StoreCollectionFieldStrategy.java:608)
at org.apache.openjpa.jdbc.meta.FieldMapping.load(FieldMapping.java:822)
at org.apache.openjpa.jdbc.kernel.JDBCStoreManager.load(JDBCStoreManager.java:682)
at org.apache.openjpa.kernel.DelegatingStoreManager.load(DelegatingStoreManager.java:116)
at org.apache.openjpa.kernel.ROPStoreManager.load(ROPStoreManager.java:78)