[jboss-user] [EJB 3.0] - Re: @GeneratedValue in mappedSuperclass Problem

fhh do-not-reply at jboss.com
Sun Nov 19 10:33:58 EST 2006


Hi!

I had the same problem. I do not have a solution but a work-around is to overwrite the getId()-method and put the @Id- and @Generated-annotation  there:


  | @Entity
  | public static class TestEntity extends EntityWithIntId implements Serializable
  | 
  |   @Id
  |   @GeneratedValue
  |   getId() {
  | 
  |     return super.getId();
  | 
  |   }
  | }
  | 
Regards

fhh

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

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3987152



More information about the jboss-user mailing list