|OneToOne Mapping Exception [message #1265845]
||Thu, 06 March 2014 16:28
| Subhadip Chatterjee
Registered: December 2013
I am using a Workbench project and getting one deployment-xml exported, to use in a Web-Application.
The below error is a recurring one, which is blocking the functional testing.
To set the context, it is a non-JPA project and a migration attempt from TopLink 9.0.4
For this particular issues, two tables are involved:
Vista_Rule and Vista_Rule_Applicability
The first table refers to the second one, with a One-to-One relational mapping.
The Data-mapping objects are Rule.java [for Vista_Rule] & Applicability.java [Vista_Rule_Applicability]. These are again non-JPA types. A custom framework (quite a old one), maps the resp. results with these objects.
When I mapped the descriptors of these tables, using the WorkBench, I found that Rule has an attribute & one-to-one mapping for Applicability.
Again, Applicability, has an attribute & one-to-one mapping for Rule. So, when a sql query is executed, to fetch a Rule-record, the below exception occurs.
Ideally, it should bear with a NoContainerPolicy whereas due to unknown reason it is receiving ContainerIndirectionPolicy [as if it is a one-to-many]
Exception Description: The operation [buildContainer constructor (null) Failed: java.lang.NullPointerException] is invalid for this indirection policy [org.eclipse.persistence.internal.indirection.ContainerIndirectionPolicy@ebc1f0ed].
Descriptor: RelationalDescriptor(com.vista.business.ruleengine.rules.Rule --> [DatabaseTable(VISTA_RULE)])
Please suggest. It is quite urgent for the testing of this project.
Powered by FUDForum
. Page generated in 0.03205 seconds