在用hibernate做开发时,有时候会遇到org.hibernate.exception.SQLGrammarException:could not insert这样的错误。
错误原因:一般是数据库表中的字段包含了数据库的关键字(保留字)
处理方法:修改数据库中和关键字产生冲突的字段名,重新映射字段名和bean中的类名
在用hibernate做开发时,有时候会遇到org.hibernate.exception.SQLGrammarException:could not insert这样的错误。