|
Bummer. I hate when programmers do that. Poor mans solution: I suggest you lock the record. Then, if the job is somehow terminated, the lock will be removed by the system. If it's not feasible to lock exactly that record, then create a surrogate lock file, write the key to the record there, and then lock it. If you can lock it, the record is yours. If not, another workstation has it - if all programs are coded to use the same access method. Whether a database field, or a real record lock is used, you still have decide how to deal with the 'user went to lunch with a record locked' problem. One vendors package that I know of clears the 'in use' flag every night at midnight. At least then all the records are available again in the morning. Otherwise, try journaling and commitment control. If the transaction is unsuccessful, the system can be set up to roll back the change to the 'in use' flag, as well as any changes not completed by that session. >There are programs here that update a field in a file to indicate the record >(and other associated records that do not have this field updated) is in use >by workstation. Trouble is, if the job is ended because of external factors >like the terminal being shut down or communications between the terminal and >the controller being terminated, we have to manually reset this field.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.