File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes update-locking Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "update-locking" Watch "update-locking" New topic
Author

update-locking

Goran Borozan
Greenhorn

Joined: May 26, 2004
Posts: 14
Hi !
In my GUI i hava a pop-up dialog that allow the user to book room.
My question is: Is it better to try to lock when the pop-up window creates(risk that the user forget the window and tge record is locked) or lock when the user is finished with writing the owner name(risk for overwriting)?



Thanks
/Goran


SCJP, SCJD, SCA (in progress)
Serkan Yazici
Ranch Hand

Joined: Apr 24, 2004
Posts: 33
Hi Goran,

I think it would be better the minimise the amount of time after locking a record. In my project, I didn't display a dialog for booking (handled on the main gui) but if I did; I would do the booking after the dialog but also check for record inconsistency (making sure the record key is not changed).


-- SCJP 1.4 (98%), SCJD (98%), SCWCD (96%), OCA Dev (97% avg.), SCBCD (97%), SCJP 1.5 BETA (90%)<br />-- OCP Dev (maybe), MCDBA (probably) SCEA (eventually)<br />-- Haven't tried Firefox yet? Free, open, secure, fast, tabified, and slick!<br />-- <a href="http://www.mozilla.org/products/firefox/" target="_blank" rel="nofollow">http://www.mozilla.org/products/firefox/</a>
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: update-locking
 
Similar Threads
NX: Passed B&S 387/400
SCJD failed, help needed with locking!
forced to lock and then read
NX: URLyBird questions about database
NX: Client side lock vs Server side lock