进行http://localhost:8088/user/forget_check_answer.do测试时,报错?
来源:6-9 用户模块所有功能自测试
Diviner0359
2018-01-16
报500 Internal Server Error
错控制台报错
Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: FUNCTION mmall_learning.COUNT does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual
### The error may exist in file [E:\tts9\JAVA_TOOLS\tts9\apache-tomcat-7.0.67\webapps\ROOT\WEB-INF\classes\mappers\UserMapper.xml]
### The error may involve com.mmall.dao.UserMapper.checkAnswer-Inline
### The error occurred while setting parameters
### SQL: SELECT COUNT (1) from mmall_user WHERE username = ? and question = ? and answer = ?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: FUNCTION mmall_learning.COUNT does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual
; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: FUNCTION mmall_learning.COUNT does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual] with root cause
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: FUNCTION mmall_learning.COUNT does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
3回答
-
Diviner0359
提问者
2018-01-16
自己已经查证解决,我的代码sql语句写的有问题!
10 -
我梦寐以求是真爱与自由
2018-02-03
我也遇到了欸。但是我的sql没问题啊,
控制台的输出是
[19:45:59.717][DEBUG][org.mybatis.spring.SqlSessionUtils][http-nio-8088-exec-1] Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@7e755e5] [19:46:25.235][DEBUG][org.mybatis.spring.SqlSessionUtils][http-nio-8088-exec-3] Creating a new SqlSession [19:46:25.236][DEBUG][org.mybatis.spring.SqlSessionUtils][http-nio-8088-exec-3] SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@30f5b369] was not registered for synchronization because synchronization is not active [19:46:25.237][DEBUG][o.m.s.t.SpringManagedTransaction][http-nio-8088-exec-3] JDBC Connection [jdbc:mysql://localhost:3306/mmall_learning?characterEncoding=utf-8, UserName=root@localhost, MySQL-AB JDBC Driver] will not be managed by Spring [19:46:25.237][DEBUG][com.mmall.dao.UserMapper.checkAnswer][http-nio-8088-exec-3] ==> Preparing: SELECT COUNT (1) FROM mmall_user WHERE username=? AND question=? AND answer=? [19:46:25.238][DEBUG][com.mmall.dao.UserMapper.checkAnswer][http-nio-8088-exec-3] ==> Parameters: admin(String), 问题(String), 123(String) [19:46:25.239][DEBUG][org.mybatis.spring.SqlSessionUtils][http-nio-8088-exec-3] Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@30f5b369]
页面上是
022019-07-24 -
Geely
2018-01-20
赞,解决了就好,够细心!
【这个帖子好好看看哟,给同学们整理的学习课程的集锦宝典】
课程项目思维导图及线上环境、测试环境、部署linux和windows等解答
http://www.imooc.com/article/20193
部署环境的话 ,建议看下文章最后一小段哟~首先跟着课程阿里云部署那个章节过一遍,可以先不跟着操作,做到心里有数,环境部署都做了什么。
尽快进入咱们QQ群哟~~进群方法下面思维导图那个帖子有。非常详细
课程项目思维导图及线上环境、测试环境、部署linux和windows等解答
http://www.imooc.com/article/20193
【重点】问答区常见问题整理
http://www.imooc.com/article/18998
课程项目QQ群分享手记
http://www.imooc.com/article/19094
找工作的季节之简历及找工作的分享
http://www.imooc.com/article/19998
项目环境、vsftpd、linux、mysql等各种配置、软件下载
http://learning.happymmall.com
mybatis-plugin插件安装
http://coding.imooc.com/learn/questiondetail/36007.html00
相似问题