• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate: subclass with foreign key as discriminator

 
Ranch Hand
Posts: 132
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
G'day to all!

I'm currently trying to implement some kind different kind of Lookup Values in one Table. So for instance a Currency, Country, Cities etc, etc all in one table.
Looking something like this: id, code, description, type_id where type is an id pointing to a meta lookupvalue expressing the type like Currency,
Country, City etc. I want to implement the various Lookup types as a subclass on the Master Lookup, I know I can discriminate on the value of the type, but it would be nice if I could discrimintate on the value inside the meta-lookup lookup type.
something like

regards and best wishes,
Jeroen.
 
reply
    Bookmark Topic Watch Topic
  • New Topic