• Post Reply Bookmark Topic Watch Topic
  • New Topic

nullifyTransientReferences

 
srini carry
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was looking into hibernate code in performsaveorupdate It calls ForeignKeys.nullifyTransientReferences this method nullifies treansient instances from an entity I don,t know when this would nullify transient instances , can
hibernate gurus here explain me what this methd does ?
 
Trilochan Bharadwaj
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
did a bit of digging, here we go and I think Hibernate folks need someone to javadoc their stuff dammit! (and format their source, perhaps?):


If a foreign key points to a transient instance ... your SQL flush is definitely going to fail ... so its safe to nullify.


Trilochan.
 
my overalls have superpowers - they repel people who think fashion is important. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!