为了账号安全,请及时绑定邮箱和手机立即绑定

急急急,大佬们,帮我看看这个错!!!

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'areaDao' defined in file [F:\springBootMybatis\target\classes\com\imooc\demo\dao\AreaDao.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [com/imooc/demo/config/dao/SessionFactoryConfiguration.class]: Invocation of init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'file [F:\springBootMybatis\target\classes\mapper\AreaDao.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error creating document instance.  Cause: java.io.FileNotFoundException: http://www.mybatis.org/dtd/mybatis-3-config-mapper.dtd

正在回答

2 回答

楼上正解,肯定是mapper.xml文件粗心写错了。实在找不到问题的话复制老师的试验。之后可能会出现一个日期异常。出现原因没找到,应该是bean中的date类型和数据库中的不一致,可以先考虑把date换成string

0 回复 有任何疑惑可以回复我~

\mapper\AreaDao.xml文件有错,解析失败,java.io.FileNotFoundException: http://www.mybatis.org/dtd/mybatis-3-config-mapper.dtd有可能是mybatis 的dtd头文件引入有误,或者映射文件sql写错了,你检查一下

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

急急急,大佬们,帮我看看这个错!!!

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信