Hi all
I am using Spring and Hiernate to access an Oracle database. I have my service under Spring.
the following is the structure and I made sure that I am not getting the error from the interceptor. It is throwing from the check() method from the abstractDAyaAccessXXXXX class. If you see my code you can see that I do make some database calls to make some validations before saving. If I comment out my validations, this code is working fine. I have single session set to "true" in the web.xml. Any ideas Gurus?????
From My action
MyService.SAveMyData(DTO)
MyService
public Collection saveMyData(Dto dto){
Collections errors = validateme(dto);
if(!errors.isEmpty){
return errors;
}
saveMyGoodData(dto);
return null;
}
public Collection validateMe(dto){
// call some name querries to access table InnerPojo and do some validations
// Do my validations here
return errors;
}
public void saveMyGoodData(Dt dto){
BaPojo ba = (BaPojo )getTemplate().findbyPrimaryKey(BaPojo.class,dto.g etKey());
InnerPojo inPojo = ba.getInnerPojo();
//set values to innerPojo
getTemplate().saveOrUpdate(inPojo );
ba.setInnerPojo(inPojo );
getTemplate().saveOrUpdate(ba);
}


Reply With Quote