• 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 mapping pojo/fields to different tables.

 
Ranch Hand
Posts: 479
1
IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I need to map a POJO to different tables/columns. In my application I have a Search option where the search filters are fetched from different tables. For e.g there are drop downs on the search page with each containing primary keys of corresponding tables. The search option is performed on a different table with the selected values. Once a user selects any of the displayed rows I have to update another table in the database with the values. Can the same POJO be mapped to different tables. I dont need a JOIN or MANY-TO-MANY sort of mapping in this case.

For e.g

POJO:-

During the search I fetch values from the Make and Model table and display them in drop downs. If the user selects any of the result and clicks Update I have to update Table4 with the values. How do I go about this?
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic