PostgreSQL, Sybase]
2018-04-12 14:18:55 [org.springframework.jdbc.support.SQLErrorCodesFactory]-[DEBUG] Looking up default SQLErrorCodes for DataSource [{
CreateTime:"2018-04-12 14:18:43",
ActiveCount:1,
PoolingCount:0,
CreateCount:1,
DestroyCount:0,
CloseCount:0,
ConnectCount:1,
Connections:[
]
}]
2018-04-12 14:18:55 [org.springframework.jdbc.support.SQLErrorCodesFactory]-[DEBUG] Database product name cached for DataSource [[email protected]]: name is ‘MySQL‘
2018-04-12 14:18:55 [org.springframework.jdbc.support.SQLErrorCodesFactory]-[DEBUG] SQL error codes for ‘MySQL‘ found
2018-04-12 14:18:55 [org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator]-[DEBUG] Translating SQLException with SQL state ‘42000‘, error code ‘1064‘, message [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1]; SQL was [] for task [
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
### The error may exist in file [D:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp3\wtpwebapps\easyleAdmin\WEB-INF\classes\com\yxl\manager\dao\mapper\UserAdminMapper.xml]
### The error may involve com.yxl.manager.dao.UserAdminDAO.selectCountEntity-Inline
### The error occurred while setting parameters
### SQL: select count(*) user_info u LEFT JOIN admin_info a on a.user_id=u.id WHERE u.user_type=?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
]
2018-04-12 14:18:55 [org.mybatis.spring.SqlSessionUtils]-[DEBUG] Transaction synchronization deregistering SqlSession [[email protected]]
2018-04-12 14:18:55 [org.mybatis.spring.SqlSessionUtils]-[DEBUG] Transaction synchronization closing SqlSession [[email protected]]
2018-04-12 14:18:55 [org.springframework.jdbc.datasource.DataSourceUtils]-[DEBUG] Returning JDBC Connection to DataSource
2018-04-12 14:18:55 [org.springframework.jdbc.datasource.DataSourceTransactionManager]-[DEBUG] Should roll back transaction but cannot - no transaction available
2018-04-12 14:18:55 [org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver]-[DEBUG] Resolving exception from handler [public org.springframework.web.servlet.ModelAndView com.yxl.manager.controller.UserAdminController.teacherList(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse,com.yxl.manager.common.Pager,com.yxl.manager.common.SelectBean)]: org.springframework.jdbc.BadSqlGrammarException:
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
### The error may exist in file [D:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp3\wtpwebapps\easyleAdmin\WEB-INF\classes\com\yxl\manager\dao\mapper\UserAdminMapper.xml]
### The error may involve com.yxl.manager.dao.UserAdminDAO.selectCountEntity-Inline
### The error occurred while setting parameters
### SQL: select count(*) user_info u LEFT JOIN admin_info a on a.user_id=u.id WHERE u.user_type=?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
2018-04-12 14:18:55 [org.springframework.web.servlet.mvc.annotation.ResponseStatusExceptionResolver]-[DEBUG] Resolving exception from handler [public org.springframework.web.servlet.ModelAndView com.yxl.manager.controller.UserAdminController.teacherList(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse,com.yxl.manager.common.Pager,com.yxl.manager.common.SelectBean)]: org.springframework.jdbc.BadSqlGrammarException:
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
### The error may exist in file [D:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp3\wtpwebapps\easyleAdmin\WEB-INF\classes\com\yxl\manager\dao\mapper\UserAdminMapper.xml]
### The error may involve com.yxl.manager.dao.UserAdminDAO.selectCountEntity-Inline
### The error occurred while setting parameters
### SQL: select count(*) user_info u LEFT JOIN admin_info a on a.user_id=u.id WHERE u.user_type=?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
2018-04-12 14:18:55 [org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver]-[DEBUG] Resolving exception from handler [public org.springframework.web.servlet.ModelAndView com.yxl.manager.controller.UserAdminController.teacherList(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse,com.yxl.manager.common.Pager,com.yxl.manager.common.SelectBean)]: org.springframework.jdbc.BadSqlGrammarException:
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
### The error may exist in file [D:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp3\wtpwebapps\easyleAdmin\WEB-INF\classes\com\yxl\manager\dao\mapper\UserAdminMapper.xml]
### The error may involve com.yxl.manager.dao.UserAdminDAO.selectCountEntity-Inline
### The error occurred while setting parameters
### SQL: select count(*) user_info u LEFT JOIN admin_info a on a.user_id=u.id WHERE u.user_type=?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
; bad SQL grammar []; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
2018-04-12 14:18:55 [org.springframework.web.servlet.DispatcherServlet]-[DEBUG] Could not complete request
org.springframework.jdbc.BadSqlGrammarException:
### Error querying database. Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
WHERE u.user_type=‘10‘‘ at line 1
### The error may exist in file [D:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp3\wtpwebapps\easyleAdmin\WEB-INF\classes\com\yxl\manager\dao\mapper\UserAdminMapper.xml]
### The error may involve com.yxl.manager.dao.UserAdminDAO.selectCountEntity-Inline
### The error occurred while setting parameters
### SQL: select count(*) user_info u LEFT JOIN admin_info a on a.user_id=u.id WHERE u.user_type=?
### Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘u LEFT JOIN admin_info a on a.user_id=u.id
错了不止一回 我是用SSM,这是数据库语言错误,检查下near附近的数据库语言
Translating SQLException with SQL state '42000', error code '1064'错误
原文地址:https://www.cnblogs.com/yaNew/p/8807555.html