Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] Setting Foreign Reference Mappings to Read-Only

Hi All

To avoid ECLIPSELINK-00046, ECLIPSELINK-00048 (http://wiki.eclipse.org/EclipseLink_Exception_Error_Reference_%28ELUG%29) with Dynamic JPA, I am planning to use the following strategy.

If a DirectToFieldMapping is defined for a primary key field of a DynamicType, then for any OneToOneMapping that uses this field set the OneToOneMapping as read-only.

Can someone please clarify the following:

1. Is the above a reasonable and safe way to avoid the exceptions at runtime?

2. What is the impact of having a foreign reference mapping as read-only? Can I not persist changes to the target entity of the mapping?


--
Thanks and Regards
Rohit Banga
Member Technical Staff
Oracle Server Technologies

Back to the top