[jboss-user] [EJB 3.0] - Re: Question about sequences and entity ejbs 3.0

fhh do-not-reply at jboss.com
Mon Apr 2 18:12:49 EDT 2007


Well on my database primary keys are usually not changed by an update. So your example would look like this:

anonymous wrote : 
  | pk 	key 	name
  | 1	1 	johm	(this is an insert)
  | 1	1 	john	(this is an update)
  | 2	2 	Pat	(this is an insert)
  | 

If you want a column that increments on updates look at the @version annotation or use a trigger.

Regards

Felix


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

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



More information about the jboss-user mailing list