-->
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.  [ 1 post ] 
Author Message
 Post subject: id generator interchangeability between MySQL and Oracle
PostPosted: Thu Mar 06, 2008 6:37 am 
Newbie

Joined: Tue Jan 29, 2008 6:37 pm
Posts: 9
I need to develop an application with hibernate using MySQL and this must be deployed in production with an oracle DB.

But I know that not everything will work as i would expect then, one of those things is ID generation.

if I would use the following hibernate annotations to make it work in MySQL:

Code:
@Id
@GeneratedValue(strategy=GenerationType.AUTO)
private Long id;


would that also work in oracle? because if I would use SequenceGenerators then I would have problems with MySQL.

The goal of this is to use Hibernate in such a way that it absolutely doesn't matter which database it uses.


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

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.