mybitis: Cannot resolve referenc

2017-04-27  本文已影响0人  橙小光
警告: Bean creation exception on non-lazy FactoryBean type check: 
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'UserMapper' 
defined in URL [file:/D:/iflytekStudy/myproject/target/classes/spring-mvc.xml]: Cannot resolve reference to 
bean 'sqlSessionFactory' while setting bean property 'sqlSessionFactory'; nested exception is 
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 
'sqlSessionFactory' defined in URL [file:/D:/iflytekStudy/myproject/target/classes/spring-mvc.xml]: Invocation of 
init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping 
resource: 'file [D:\iflytekStudy\myproject\target\classes\mapper\UserMapper.xml]'; nested exception is 
org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. Cause: 
org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: 
org.apache.ibatis.type.TypeException: Could not resolve type alias 'com.iflytek.cms.pojo.User'.  Cause: 
java.lang.ClassNotFoundException: Cannot find class: com.iflytek.cms.pojo.User

Paste_Image.png

**
用generator时出现的错误:这个错误的地方不在mybatis配置文件,在mapper.xml中:
**

Paste_Image.png
上一篇下一篇

猜你喜欢

热点阅读