I'd like to use an embeddedID for some of my classes. Th class PK is an 
embeddable, it contains one field:

  | private long id;

I'd like to generate the value, I've try:
@Id
  |   @GeneratedValue(strategy = GenerationType.TABLE)
  |   @Column(name="CUST_ID")
  |   private long id;

In that case annotaions are not used (PK is not generated).

Any idea how to have a generatedValue for a PK in a embeddedID ?

PS: I'd like to use an embedded ID for typing the PK. I do not like to see long 
everywhere in the application. It may be bug prone.

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

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


_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to