2018-03-14 23:06

2018-03-18  本文已影响0人  TiddAr

scene:

Floor entity has dormitories (Set) field,Dormitory entity has student (Set) field,when I  import them from an excel table and batch save students use hibernate ,the struct of the excel table like that

Clearly there is no 'floor.ID' or 'dormitory.ID' field in the table,so hibernate will insert a new floor entity into database=-=.and then---->

solution:

After I get student entity I query the

   

上一篇下一篇

猜你喜欢

热点阅读