Bug 441544 - TREAT() table per class inheritance strategy support
Summary: TREAT() table per class inheritance strategy support
Status: NEW
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: All Unix All
: P3 enhancement with 2 votes (vote)
Target Milestone: ---   Edit
Assignee: Nobody - feel free to take it CLA
QA Contact:
URL:
Whiteboard:
Keywords: api
Depends on:
Blocks:
 
Reported: 2014-08-11 16:07 EDT by David Winters CLA
Modified: 2022-06-09 10:19 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Winters CLA 2014-08-11 16:07:53 EDT
In EclipseLink 2.5.2, using the TREAT() operator in a query on entities which use the inheritance strategy table per class does not work. Since support for table per class is optional in the JPA 2.1 specification, it has not been implemented it would appear in EclipseLink. I have tested with the latest EclipseLink version 2.5.2. It does not work for single-table and joined inheritance strategies since they both use an inheritance policy rather than an interface policy which is used for entities with  an inheritance strategy table per class. Please see defect 374771 for reference whereby support for the TREAT operator was implemented in EclipseLink 2.5.1 to comply with the JPA 2.1 specification. An implementation for entities using the ihnertiance strategy table per class should be also provided so that one can downcast types using this inheritance strategy.
Comment 1 David Winters CLA 2014-08-11 16:13:30 EDT
Just to clarify, using the TREAT operator on queries work for single-table and joined inheritance strategies since they both use an inheritance policy rather than an interface policy which is used for entities with an inheritance strategy table per class.
Comment 2 Asaf Natan CLA 2016-10-03 09:58:47 EDT
any news regarding this feature ?
Comment 3 Eclipse Webmaster CLA 2022-06-09 10:19:38 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink