严重: Exception sending context initialized event to listener instance of class [org.springframework.web.context.ContextLoaderListener]
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'betsServiceImpl': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [cn.bobi.dao.bets.BetsDao] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.annotation.Resource(shareable=true, lookup=, name=, description=, authenticationType=CONTAINER, type=class java.lang.Object, mappedName=)}
Related cause: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'betsDao' defined in file [C:\Users\Administrator\eclipse-workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\bibo\WEB-INF\classes\cn\bobi\dao\bets\BetsDao.class]: Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: org.apache.ibatis.builder.BuilderException: Error creating document instance. Cause: org.xml.sax.SAXParseException; lineNumber: 38; columnNumber: 52; 元素内容必须由格式正确的字符数据或标记组成。
你这截图看不到完整的sql。。。
看不到完整sql。从一下两个方面看这个问题:
1. 加上group by的语句,在sql 查询窗口是否正确执行?如果否,调整sql语句为正确语法
2.从错误提示看,更像xml的语法错误,例如标记错误或加入了不可识别字符
group by 分组的字段 必须在select语句中出现过才可以,不然会出问题
group by 后面的字段也要加表的别名.字段名