Re: ODMG Delete : markDelete or deletePersistent
Armin Waibel <[email protected]>
| Newsgroups | gmane.comp.jakarta.ojb.user |
|---|---|
| Message-ID | <[email protected]> |
Hi Bruno, Bruno CROS wrote: > Hi, > > Just one question. > > Using ODMG, if deletePersistent(o) is called from the Impl.getDatabase(), > how "SQL DELETE" query post can be done with the other "INSERT/UPDATE" in > the same SQL transaction without refering THE transaction? Within the Database object the tx associated with the current thread is used to lock and markForDelete the specified object. > Why ODMG delete > object tutorial talk about deletePersitent way, whereas > ExtTx.markDelete(o) would > be more appropriate considering SQL queries sequence in transaction? > Because Database#deletePersistent is the standard method to delete objects in ODMG. It does nearly the same as #markDelete(o), it simply calls TransactionImpl#deletePersistent on the current associated tx object. regards, Armin > Need help. > > Regards. > > Bruno >