Skip to content

eanurku/Hibernate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ERROR and solution:

  1. ERROR: Field 'employee_id' doesn't have a default value solution: primary key identifier employee_id should be set as auto_increment .

ERROR: Dec 09, 2019 10:28:35 PM org.hibernate.engine.loading.internal.LoadContexts cleanup WARN: HHH000100: Fail-safe cleanup (collections) : org.hibernate.engine.loading.internal.CollectionLoadContext@1de9d54<rs=Result set representing update count of 3> Dec 09, 2019 10:28:35 PM org.hibernate.engine.loading.internal.CollectionLoadContext cleanup WARN: HHH000160: On CollectionLoadContext#cleanup, localLoadingCollectionKeys contained [1] entries

solution: this kind of error occurs if foreign key is refrencing the row but index or list-index column is null and hibernate try to do mapping for list/map. in case of NULL list-index value(related to tag) ,replace index value to int values like 0,1,2 as they are index position in list. in case of index column is NULL(related to tag),either remove these rows or replace it with Non-Null values.

ERROR: Table 'testdb.hibernate_sequence' doesn't exist

solution: set strategy to Identity in GeneratedValue annotation as given below instead of sequence or auto .

@GeneratedValue(strategy = GenerationType.IDENTITY)

ERROR: org.hibernate.MappingException: Unknown entity: com.model.Student

solution : add class mapping in hibernate.cfg.xml file 5. Exception occured : org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.model.Student.studentSkills, could not initialize proxy - no Session

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages