-->
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.  [ 6 posts ] 
Author Message
 Post subject: Custom SQL for CRUD with annotations
PostPosted: Mon Jun 13, 2005 4:51 am 
Newbie

Joined: Wed May 25, 2005 7:24 am
Posts: 11
Location: Austria
hi!

in hibernate3 there is the possiblity to use custom sql queries for
CRUD operations.
is it also possible to define this with annotations?

thx


Top
 Profile  
 
 Post subject: Re: Custom SQL for CRUD with annotations
PostPosted: Tue Jun 14, 2005 7:19 pm 
Regular
Regular

Joined: Thu Jul 08, 2004 1:21 pm
Posts: 68
Location: Recife - Pernambuco - Brazil
alsayno wrote:
hi!

in hibernate3 there is the possiblity to use custom sql queries for
CRUD operations.

Yes, please, read the following chapter from docs:
17.4. Custom SQL for create, update and delete
alsayno wrote:
is it also possible to define this with annotations?

thx

No yet!

valeuz...

_________________
Marcos Silva Pereira
http://blastemica.blogspot.com


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 16, 2005 8:58 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
patch welcome

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jun 17, 2005 3:24 pm 
Regular
Regular

Joined: Thu Jul 08, 2004 1:21 pm
Posts: 68
Location: Recife - Pernambuco - Brazil
I think that put custom crud sql in annotations is not a good idea. First because it is a dba task and second because alter some sql will require a new compilation of code. Anyway, it could be useful because for now you cannot mix (for the same class) XML and annotations mapping.

valeuz...

_________________
Marcos Silva Pereira
http://blastemica.blogspot.com


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 22, 2005 6:52 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
Well since you're packaging your xml files anyway, extra compilation usually doesn't hurt.

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 30, 2005 1:46 pm 
Regular
Regular

Joined: Thu Jul 08, 2004 1:21 pm
Posts: 68
Location: Recife - Pernambuco - Brazil
emmanuel wrote:
Well since you're packaging your xml files anyway, extra compilation usually doesn't hurt.

Right, how do you plan to do it? Maybe using a package-info could be a good approach.

best regards

_________________
Marcos Silva Pereira
http://blastemica.blogspot.com


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 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.