aspose file tools
The moose likes Object Relational Mapping and the fly likes ON UPDATE RESTRICT in cascade? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Barcodes with iOS this week in the iOS forum
or Core Java for the Impatient in the Java 8 forum!

JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "ON UPDATE RESTRICT in cascade?" Watch "ON UPDATE RESTRICT in cascade?" New topic


nimo frey
Ranch Hand

Joined: Jun 28, 2008
Posts: 580
Is this SQL:

the same as this:

(How can I do the update restrict? Is this implicitly set with this annotation?

Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

It looks the same, but it isn't. The big difference is where your database supports on update restrict and on delete cascade (not all do) this will happen all the time, regardless of which application connects to the database to manipulate the date. In the case of an ORM offering this behaviour it will happen only when that specific application manipulates the data.

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
I agree. Here's the link:
subject: ON UPDATE RESTRICT in cascade?