Hello ! I'm new to iBatis and I'm trying to setup resultMaps with inheritance support. I've read the Data Mapper Guide v1.5.1 section 3.5.6 but the case studied there is not the same as the case I have here, my case is really simple, I have 2 tables and 2 classes:

Person
=====
PersonID
Name
Address

Student
======
StudentID
PersonID
Grade

public class Person { ... }

public class Student : Person { ... }

My idea was that I could setup 2 resultMaps, Person and Student, and relate them with inheritance, meaning that when I called the resultMap for the Student it would also call the resultMap for Person, but I don't know if that is possible. Can somebody give me a hand on how to deal with that problem ? I just didn't want to have one select for Person and a JOIN select for Student.

thank you
Anderson Fortaleza

Reply via email to