Hibernate supports polymorphic queries.  So you can write an interface and have 
the two entity classes implement that interface.

When you query the interface with no restrictions/criteria in where clause, for 
example, you'll get all records from both tables.

read more in Ch. 5 of JPA/Hibernate book.

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4227345#4227345

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4227345
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to