Sorry, this description is much too vague to be able to offer any useful advice. What version of iBATIS are you using? You would need to show the result map from the initial getAllObjects() and the subsequent getSomeValue().

What is the value of "hash" being passed into getSomeValue()? In order for a field in MyObject to be set to null (if I'm understanding what you are saying), the result map for getSomeValue() would have to be pointed at either that field directly or the parent MyObject.

On 3/29/2010 4:59 AM, foeke99 wrote:

I have this strange problem which i can't get to solve
I have an arraylist of objects and each object has several child objects
which are perfectly loaded with the config file.


ArrayList<MyObject>  objects = _testMapper.getAllObjects();

at one point i have to split these into 2 arraylists based on a flag
variable in each object

then i pass these arraylists through the next stage

But in the last stage of my program when i want to make a minor call to
retrieve a value from within the same mapper file the child objects of each
object in my arraylist is instantiated to null

So when i debug i can see that before the call everything is fine and after
the call

int value =_testMapper.getSomeValue(hash);

the child objects are instantiated to null !

if i don't make a call from _testMapper everything runs fine.

Has anyone experienced the same problem or is there something i've done
wrong ?


greetz






--
Guy Rouillier

---------------------------------------------------------------------
To unsubscribe, e-mail: user-java-unsubscr...@ibatis.apache.org
For additional commands, e-mail: user-java-h...@ibatis.apache.org

Reply via email to