天天看点

hibernate使用注意事项1

报错信息:org.hibernate.exception.SQLGrammarException: could not execute statement

原因之一就是用了mysql的关键字做了表名,比如order

如果用了mysql关键字做了表名,那么就会造成各种问题,而且不容易排查,所以在定义表时,尽量不要用关键字,特别是表名千万不要用关键字,不然会浪费很多时间。

继续阅读