ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alebu <ale...@gmail.com>
Subject Advanced Result Mapping documentation error or misunderstanding of concept
Date Wed, 19 May 2010 11:12:07 GMT
Hi, at this moment I am reading documentation "Advanced Result Mapping"
section and one think I can't understand in the example with blogs (further
reading didn't clarified it either).

SQL Query is described like:

<select id="selectBlogDetails" parameterType="int" resultMap="
B.id as *blog_id*,
B.title as blog_title,

Result set mapping for that query described like:
<resultMap id="detailedBlogResultMap" type="Blog">
<idArg *column="id"* javaType="int"/>
<result property="title" column="blog_title"/>

As I understand, the alias for block ID is *blog_id* but constructor's idArg
references to column as *id*. For all other parts of query aliases are
correct (from my POV), so is it a problem with documentation (in this case
it is repeated in further examples too), or I didn't understand something.

View raw message