-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: how can i create String type id using hibernate 3.0 & mysql
PostPosted: Sat Oct 27, 2012 7:17 am 
Newbie

Joined: Thu Oct 18, 2012 10:05 pm
Posts: 2
I am using hibernate 3.0 , struts 2 and mysql
using cfg and hbm file ..
I created integer id as primary key using

<class name="Employee" table="EMPLOYEE">
<id name="employeeId" column="EMPLOYEE_ID">
<generator class="" />
</id>

but i also wana to create other unique STRING TYPE key like

EMP10001 , EMP10002 .. SO ON

SO HOW CAN I CREATE IT ??


Top
 Profile  
 
 Post subject: Re: how can i create String type id using hibernate 3.0 & mysql
PostPosted: Sat Nov 10, 2012 2:43 am 
Newbie

Joined: Thu Oct 18, 2012 10:05 pm
Posts: 2
any body know about this ?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.