Frank, I don't know if there is a Java class that allows you to specify record locks, but this is not a requirement for multi-user systems. SQL dos not support this except through commitment control. You can easily simulate a simple lock by comparing the record at update with an image saved when the record was read. Or, you can use an update count in the record to accomplish this. If what you want is to make sure that a set of records is updated, commitment control would be the best method. If what you really want is to lock a record without a subsequent update, I would add a field that contains the "lockers" id and a method to clear the lock, after verification, without outside involvement. You don't want to have to run a fix in the event of a power failure, etc. David Morris >>> "David Murphy" <email@example.com> 11/16 2:19 PM >>> Good luck, Frank! I subscribed to this list over a week ago and yours is the first message I've seen! David Murphy Information Services Oregon State Scholarship Commission 1500 Valley River Drive Eugene, OR 97401 (541) 687-7433 -----Original Message----- From: firstname.lastname@example.org On Behalf Of DeSarro Frank Sent: Monday, November 16, 1998 8:25 AM To: JAVA400-L@midrange.com Subject: AS400 ToolBox for Java - Record locking I'm new to this mailing list. I apologize if this question has been asked previously. I'm trying to lock a record using the record level access classes included in the Toolbox. I can not find anything in the Toolbox documentation to set a record lock using the record level access classes. Is there a way to lock a record using the record level access classes? I know using sequential access you can lock a number of bytes, but sequential access is not what I want. I don't want to lock the file either. Any help with this matter would be greatly appreciated. A record lock to me would seem to be a rather standard operation needed to process data in a multi-user system. If the answer to this question is obvious, just point me to where in the documentation this is explained and I'll figure it out. Thanks. Frank DeSarro +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to JAVA400-L@midrange.com. | To subscribe to this list send email to JAVA400-L-SUB@midrange.com. | To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: email@example.com +---
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.