Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: Kristopher Davis   on Nov 19 In Java Category.

  
Question Answered By: Samuel Costa   on Nov 19

For your first question, you can create/write a query directly in HQL or even native SQL that updates a field in some table. HQL is the preferred method usually but it requires that you learn yet another query language! SQL of course, should be slightly more familiar to you, but then it might tie you to a specific database.

Second question, yes. You'll need to configure the JDBC batch  size as a Hibernate property and control the session's first level cache by using the flush() and clear() methods on the session object  once you hit the batch size in a loop or something.

Share: 

 

This Question has 4 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on Update in Hibernate2 Or get search suggestion and latest updates.


Tagged: