-->
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: Migration Hibernate 3.2 to Hibernate 4 - Blob Usage Problem
PostPosted: Mon Feb 13, 2012 11:43 pm 
Newbie

Joined: Mon Feb 13, 2012 10:47 pm
Posts: 3
Hi,

There is an application that needed to be migrated from Hibernate 3.2 to 4.0. It seems the SerializableBlob class and createBlob() method are deprecated and removed. Can any one guide me or give me any example on how to make changes to migrate hibernate 4 on the following code:

Code:
   public void updateStaffBiometric(StaffBiometrics staffBiometrics)
         throws BaseAppException {
      
      StaffBiometrics localStaffBiometrics = getStaffBiometricsDao().
               findStaffBiometricsByStaffId(staffBiometrics.getStaffId());

      SerializableBlob blobBio1 = (SerializableBlob)Hibernate.createBlob(staffBiometrics.getBioByte1());
      SerializableBlob blobBio2 = (SerializableBlob)Hibernate.createBlob(staffBiometrics.getBioByte2());

      localStaffBiometrics.setBiometrics1(blobBio1);
      localStaffBiometrics.setBiometrics2(blobBio2);
      
      ....
   }



Please.. any help is highly appreciated.


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.