This Bugzilla instance is deprecated, and most Eclipse projects now use GitHub or Eclipse GitLab. Please see the deprecation plan for details.
Bug 374771 - JPA 2.1 TREAT support
Summary: JPA 2.1 TREAT support
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Nobody - feel free to take it CLA
QA Contact:
URL: http://wiki.eclipse.org/EclipseLink/D...
Whiteboard:
Keywords:
: 410406 (view as bug list)
Depends on:
Blocks: 385350 338610
  Show dependency tree
 
Reported: 2012-03-20 11:03 EDT by Gordon Yorke CLA
Modified: 2022-06-09 10:32 EDT (History)
3 users (show)

See Also:


Attachments
POC (76.96 KB, patch)
2012-12-03 17:10 EST, Chris Delahunt CLA
no flags Details | Diff
Criteria API support and test cases (143.52 KB, patch)
2013-02-08 21:31 EST, Chris Delahunt CLA
no flags Details | Diff
proposed fix and test changes (161.54 KB, patch)
2013-06-11 15:37 EDT, Chris Delahunt CLA
no flags Details | Diff
proposed fix and test changes (161.88 KB, patch)
2013-06-13 15:34 EDT, Chris Delahunt CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gordon Yorke CLA 2012-03-20 11:03:51 EDT
Through JSR 338 the JPA specification will add support for "treating" a joined attribute as a subclass of the attribute type for the purpose of defining a Query expression.

Support in both JPQL and Criteria API is required.
Comment 1 Gordon Yorke CLA 2012-03-20 11:03:58 EDT
The Specification should be reviewed for requirements but a key point is this function is a join to the subclass table and any superclass results are eliminated from the result
Comment 2 Chris Delahunt CLA 2012-12-03 17:10:55 EST
Created attachment 224244 [details]
POC
Comment 3 Chris Delahunt CLA 2013-02-08 21:31:47 EST
Created attachment 226803 [details]
Criteria API support and test cases
Comment 4 Chris Delahunt CLA 2013-06-11 15:37:34 EDT
Created attachment 232259 [details]
proposed fix and test changes
Comment 5 Chris Delahunt CLA 2013-06-13 15:34:13 EDT
Created attachment 232355 [details]
proposed fix and test changes

Checked into main and 2.5.1
Comment 6 Chris Delahunt CLA 2013-06-17 09:59:34 EDT
Fix checked in supports joined and single table inheritance.  Table per class is not supported and will result in exceptions stating the cast class does not use inheritance - this is due to Table per class support using an interface policy instead of an inheritance policy
Comment 7 Chris Delahunt CLA 2013-06-17 09:59:53 EDT
*** Bug 410406 has been marked as a duplicate of this bug. ***
Comment 8 Eclipse Webmaster CLA 2022-06-09 10:32:48 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink