ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Chase" <jcha...@gmail.com>
Subject <resultMap> problems with <property> mappings
Date Mon, 12 Feb 2007 03:30:25 GMT
I'm using a result map like the following:


<resultMap id="fooResultMap" class="my.Foo" extends="
Abstract.abstractResultMap">

<result property="a" />

<result property="b" />

</resultMap>

When I use the above, for some unexplainable reason, the values for "a" and
"b" column values in the Foo class instance are off by one from the
database.  That is, the Java bean's "a" property has the value that b should
have.  If there were a "c" property as well, "b" would have "c"'s expected
value.

I can make things work correctly when I specify the columns explicitly like
this:

<result property="a" column="a" />

<result property="b" column="b" />

What in the world could cause this?

I'm using ibatis 2.3 beta, Mysql 5, Java 5.

Thanks,

Jon

Mime
View raw message