• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Setting all,delete-orphans on Many-to-One relationship?

 
Ranch Hand
Posts: 294
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all
Why isnt it possible to cascade all,delete-orphan on many-to-one relationship?

Fr example,
Car and Driver
Driver can drive several cars, when deleting car and the driver is not driving any other car - remove the driver also



I get an error:



Any suggestion?
 
Sharon whipple
Ranch Hand
Posts: 294
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
https://forums.hibernate.org/viewtopic.php?f=1&t=939229&view=next
http://opensource.atlassian.com/projects/hibernate/browse/HB-1010

Gavin King:

Orphan delete for a many-to-one is anyway semantically incorrect! (A one-to-one might make sense.)

 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic