go for logical equality, so if your entity has three fields:
| @Id
| @GeneratedValue
| private int id;
|
| private String firstName;
|
| private String lastName;
then equals/hashCode should be based on first/lastName and not id.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4105293#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...