• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

link to different table with the same key

 
Leinad Gant
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I have a question about Hibernate mapping.
assume I have a table, called "A", and one of its fields link to another table "b" by the id.
class A {
Object b;
String condition;
getter & setter method..
}

now I have another table, called "C", but the situation is, if the condition flag is = to b, get the object from "b" table, if the condition flag is = to c, get the object from "c" table.

is this possible in hibernate?
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic