ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Larry Meadors <larry.mead...@gmail.com>
Subject Re: Getting error with Bean Object property not writtable at sqlmap config initial load
Date Thu, 17 Feb 2005 18:03:09 GMT
setNetPrefixID == netPrefixID, not netPrefixID2


On Thu, 17 Feb 2005 12:59:14 -0500, Jason Hall <JHall@cihi.ca> wrote:
>  
>  
> 
> I'm get this error below. What's the problem. 
> 
> Cause: com.ibatis.common.beans.ProbeException: There is no WRITEABLE
> property named 'netPrefixID2' in class 'Network' 
>  
> 
> Network.java: 
>  
> 
> import java.io.*; 
> 
> public class Network implements Serializable { 
>         private int netPrefixID2; 
> 
>         
>         public void setNetPrefixID(int netPrefixID2) 
>         { 
>                 this.netPrefixID2 = netPrefixID2; 
>         } 
> 
>         public int getNetPrefixID() 
>         { 
>                 return netPrefixID2; 
>         } 
> 
> } 
>  
>  
>  
>  
> 
> network.xml: 
> 
> <?xml version="1.0" encoding="UTF-8" standalone="no"?> 
> <!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN"
> "http://www.ibatis.com/dtd/sql-map-2.dtd"> 
>  
>  
> 
> <sqlMap namespace="network"> 
> 
> <typeAlias alias="net" type="Network"/>      
> 
> <resultMap id="netwk" class="net">         
>         <result property="netPrefixID2" column="O1"/>         
> </resultMap>  
> 
>   <select id="getNetwork"  resultClass="netwk"
> parameterClass="java.lang.Integer"> 
>     select 
>          O1 
>     from NETWORK_PREFIX 
>     where netPrefixID = #value# 
>   </select> 
>  
> 
> </sqlMap>

Mime
View raw message