-->
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: Hibernate POJO wrapper object
PostPosted: Fri Jun 30, 2006 3:48 am 
Newbie

Joined: Sat Apr 23, 2005 6:06 pm
Posts: 6
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version:2

Name and version of the database you are using:Oracle 8.1

Hi all,

I am using Hibernate to access data from a Oracle DB in which some of the tables have been populated by a legacy system. The legacy system does not understand null (dont ask!) and all null fields which are relationships are entered as " " (space).

In Hibernate 3 there is a mapping definition in the xml file where you can ask Hibernate to ignore this char. However on Hibernate 2 this does not exist so I have had to use proxy objects.

So what I want to know is: Is there a Wrapper object that can be implemented which can intercept the call to load the object which will check before it loads the object to see if there are spaces. It cant be done after it has loaded because as soon as it tries to load the object it throws row not found because no row esixts with " ".

I am after something like the HttpServletRequestWrapper but for hibernate. I dont want to amend the source code. Is this possible? does anyone know of anything like this?

All suggestions are appreciated?

Thanks


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.