com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException:未知列';这是启用的';在';字段列表';
当我在grails localhost上运行通过spring框架过滤的url时, 表现为,com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException:未知列';这是启用的';在';字段列表';,mysql,spring-mvc,grails,spring-security,gorm,Mysql,Spring Mvc,Grails,Spring Security,Gorm,当我在grails localhost上运行通过spring框架过滤的url时, 表现为, Error: Caused by: org.springframework.jdbc.BadSqlGrammarException: Hibernate operation: could not extract ResultSet; bad SQL grammar [n/a]; nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLS
Error:
Caused by: org.springframework.jdbc.BadSqlGrammarException:
Hibernate operation: could not extract ResultSet;
bad SQL grammar [n/a];
nested exception is
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException:
Unknown column 'this_.enabled' in 'field list'
如果我从我的域类中删除启用的变量,它将显示为
Error:
org.springframework.security.authentication.InternalAuthenticationServiceException:
No such property: enabled for class: com.voonik.User.
有什么解决方法吗?向我们展示一些您访问数据库的代码。检查
用户
表是否启用了字段。如果不是,则db模式存在一些问题。如果使用db迁移,请确保有正确的迁移脚本。显然,用户表中缺少enabled
列。