報錯org.springframework.beans.factory.BeanCreationException:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘sqlsession’ defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: ‘file [D:\spring代碼.metadata.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\ssm-studentInfoManager\WEB-INF\classes\mapper\mapper.xml]’; nested exception is org.apache.ibatis.builder.BuilderException: Error parsing Mapper XML. Cause: org.apache.ibatis.builder.BuilderException: Mapper’s namespace cannot be empty
這種錯誤前面就顯示映射錯誤,其實就是後面加粗的那後面一句:mapper文件中的命名空間不能爲空。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章