ibatis+spring+mysql nested exception is com.ibatis.common.jdbc.exception.NestedSQLException:

来源:互联网 发布:mac玩美服lol加速器 编辑:程序博客网 时间:2024/06/07 09:06
org.springframework.jdbc.BadSqlGrammarException: SqlMapClient operation; bad SQL grammar []; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException:   
--- The error occurred in ibatis/account/agencyUser.xml.  
--- The error occurred while applying a result map.  
--- Check the agencyUserResult.  
--- Check the result mapping for the 'idCard' property.  

--- Cause: java.sql.SQLException: Column 'id_card' not found.


属性和字段映射的错误   

1 看看你建的类中有没有属性叫idCard; 

2 在.xml中看看resultMap中看看<result property="idCard" column="id_card"/>有没有写错

3 在其他.xml文件中看看是否有<includerefid="sentenceXXX"/>重名了的

0 0
原创粉丝点击