ibatis-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tom Bloomfield (JIRA)" <ibatis-...@incubator.apache.org>
Subject [jira] Created: (IBATIS-172) implicit mapping fails on nested column aliases
Date Tue, 19 Jul 2005 14:59:45 GMT
implicit mapping fails on nested column aliases
-----------------------------------------------

         Key: IBATIS-172
         URL: http://issues.apache.org/jira/browse/IBATIS-172
     Project: iBatis for Java
        Type: Bug
  Components: SQL Maps  
    Versions: 2.1.0, 2.1.5    
 Environment: Win2000 / Oracle
    Reporter: Tom Bloomfield
    Priority: Minor


Using the implicit mapping example below:

<select id="test" resultClass="foo">
SELECT
  1 AS "nested.col1"
FROM
  DUAL
</select>

Logic exists in ComplexBeanProbe that splits the target property name on "." when defined
as a map in the XML:

<result property="nested.col1" column="1" />

I don't see the same logic in sqlmap.engine.mapping.result.AutoResultMap ( I'm assuming this
is the
class responsible for initializing implicit queries ;-))

It appears the target class members are being introspected by ClassInfo, added to a hash of
member names, then the LITERAL column name returned by ResultSetMetaData being searched for
in that hash... (IE, we'd look
for a method named "nested.col1" in the method hash, when I really want it to look for setNested().setCol1()).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message