-->
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.  [ 4 posts ] 
Author Message
 Post subject: Bulk field updates
PostPosted: Fri Oct 15, 2004 10:08 pm 
Beginner
Beginner

Joined: Fri Oct 15, 2004 9:58 pm
Posts: 25
Is there any way to update a field of an object without fetching that object into the memory. I want to write queries like

1) update ... abc where abc.z>0
2) update .. select...

Any help would be great.

Prasad


Top
 Profile  
 
 Post subject:
PostPosted: Sat Oct 16, 2004 3:41 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Whats wrong with SQL/JDBC?

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Oct 16, 2004 9:14 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 3:00 pm
Posts: 1816
Location: Austin, TX
This will be a feature in Hibernate3


Top
 Profile  
 
 Post subject:
PostPosted: Sun Oct 17, 2004 4:59 am 
Beginner
Beginner

Joined: Fri Oct 15, 2004 9:58 pm
Posts: 25
Thanks Steve. If the syntax is available could you point me to that place?

Christian,

There is nothing wrong with JDBC/SQL, but I want to minimize the use of SQL in our code. There are large number of queries (1000s) in our app and maintainance would be hard if both SQL and HQL queries are mixed all over the place. Another reason is that the coupling between our persistence layer and the underlying schema would increase. It is hard to eliminate SQL altogether (for performance reasons) but I want to minimize those instances.

Thanks,
Prasad


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