org.apache.ibatis.reflection.ReflectionException: There is no getter for property named ‘funcS

來源:互聯網
上載者:User


org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'funcSetId' in 'class java.lang.Integer'


    at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:73)
    at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:346)
    at $Proxy6.selectList(Unknown Source)
    at org.mybatis.spring.SqlSessionTemplate.selectList(SqlSessionTemplate.java:189)
    at org.apache.ibatis.binding.MapperMethod.executeForList(MapperMethod.java:85)
    at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:65)
    at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:38)
    at $Proxy9.findExistAccount(Unknown Source)
    at com.atsig.uac.service.FunctionService.findExistAccount(FunctionService.java:61)
    at com.atsig.uac.test.UACTest.main(UACTest.java:50)
Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'funcSetId' in 'class java.lang.Integer'
    at org.apache.ibatis.reflection.Reflector.getGetInvoker(Reflector.java:308)
    at org.apache.ibatis.reflection.MetaClass.getGetInvoker(MetaClass.java:93)
    at org.apache.ibatis.reflection.wrapper.BeanWrapper.getBeanProperty(BeanWrapper.java:131)
    at org.apache.ibatis.reflection.wrapper.BeanWrapper.get(BeanWrapper.java:27)
    at org.apache.ibatis.reflection.MetaObject.getValue(MetaObject.java:103)
    at org.apache.ibatis.builder.xml.dynamic.DynamicContext$ContextMap.get(DynamicContext.java:70)
    at org.apache.ibatis.builder.xml.dynamic.DynamicContext$ContextAccessor.getProperty(DynamicContext.java:88)
    at org.apache.ibatis.ognl.OgnlRuntime.getProperty(OgnlRuntime.java:1529)
    at org.apache.ibatis.ognl.ASTProperty.getValueBody(ASTProperty.java:84)
    at org.apache.ibatis.ognl.SimpleNode.evaluateGetValueBody(SimpleNode.java:175)
    at org.apache.ibatis.ognl.SimpleNode.getValue(SimpleNode.java:213)
    at org.apache.ibatis.ognl.Ognl.getValue(Ognl.java:314)
    at org.apache.ibatis.ognl.Ognl.getValue(Ognl.java:394)
    at org.apache.ibatis.ognl.Ognl.getValue(Ognl.java:435)
    at org.apache.ibatis.ognl.Ognl.getValue(Ognl.java:414)
    at org.apache.ibatis.builder.xml.dynamic.TextSqlNode$BindingTokenParser.handleToken(TextSqlNode.java:39)
    at org.apache.ibatis.parsing.GenericTokenParser.parse(GenericTokenParser.java:25)
    at org.apache.ibatis.builder.xml.dynamic.TextSqlNode.apply(TextSqlNode.java:19)
    at org.apache.ibatis.builder.xml.dynamic.MixedSqlNode.apply(MixedSqlNode.java:14)
    at org.apache.ibatis.builder.xml.dynamic.DynamicSqlSource.getBoundSql(DynamicSqlSource.java:22)
    at org.apache.ibatis.mapping.MappedStatement.getBoundSql(MappedStatement.java:198)
    at org.apache.ibatis.executor.BaseExecutor.createCacheKey(BaseExecutor.java:115)
    at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:90)
    at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:72)
    at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:75)
    at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:69)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:338)
    ... 8 more

 

 

 



出錯原因:<select id="findExistAccount" parameterType="FuncSetBean"  resultMap="AccountBeanMap">
                       select * from SYSTEM_ACCOUNT where GROUP_ID=${funcSetId}
               </select>



parameterType需要的參數(funcSetId)類型為Integer

 

 



聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.