GeeCON Prague 2014*
The moose likes Object Relational Mapping and the fly likes Single Table Inheretance - Multiple Values Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Single Table Inheretance - Multiple Values" Watch "Single Table Inheretance - Multiple Values" New topic
Author

Single Table Inheretance - Multiple Values

Rahul Juneja
Ranch Hand

Joined: Aug 03, 2002
Posts: 425
Folks,

I am trying to create a discriminator in Hibernate Mapping and i want multiple filtered values in the subclass.

As an example i have a persons class and it has students(S), Employees(E), Players(P) with discriminator column as Type and values as S,E,P.
I want to have a subclass which has Student(S) and Players(P). Is there any way i can do this with discriminator.

Any pointers is appreciated.

Thanks,
Rahul


Rahul Juneja
ThoughtClicks - http://techlabs.thoughtclicks.com
Kuladip Yadav
Ranch Hand

Joined: Jul 30, 2008
Posts: 162

This link may be helpful to you

Inheritance Mapping

Thanks
 
GeeCON Prague 2014
 
subject: Single Table Inheretance - Multiple Values