[Log] hibernate issue summary

Q & A

Q :
Out of range value for column ‘GMPA’ at row 1

A:
incoming fields do not match with the database field types


Q : ids for this class must be manually assigned before

A:
the above mentioned id generation strategy issues


Q :
detached entity passed to persist

A:
entity class can not be resolved, the analysis of which entity class field has not been resolved
to find the cause, id mysql entity class is automatically generated, with the annotations marked

        @GeneratedValue(strategy = GenerationType.IDENTITY)

Q :
could not extract ResultSet; SQL [n/a]; nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet

A:
Check the entity classes and fields in the table whether the correspondence


Illegal mix of collations (utf8_unicode_ci,IMPLICIT) and (utf8_general_ci,IMPLICIT) for operation ‘=’

Encoding format table in the database does not

  collate = utf8_unicode_ci ; // 创建表的时候需要在最后加上
 show  full columns  from  table_name; //    查看 table_name 的列信息

Guess you like

Origin blog.csdn.net/java_sparrow/article/details/89207885