file share and automatic lock
I'm using Indexed-file with LOCK MODE IS AUTOMATIC,
also, I have these directives
$set ans85 comp
$SET AUTOLOCK FILESHARE
the file opened as i-o,
the file contains these records keys: 1, 5, 12
if user1 working on record no 5,, user2 can't add new record no 4
Can you please provide some more detail.
"if user1 working on record no 5,, user2 can't add new record no 4"
What does "working on" mean"? does this mean that user1 has successfully read the record and has it locked?
What happens when user2 tries to write the record with key = 4? What is the file status that is returned?
User 1 has successfully read the record no 5 and has it locked.
at this time User 2 has filled all required data for new record no 4 which is not existing yet when he wants to this save his work and create the new record (record 4) he can’t do it until User 1 releases record no 5 or exit from this program,,
when user 2 tries to write the record with key = 4 the file status that is returned:
File status 9/068 record locked
I cannot reproduce this behavior using Net Express with wrappack 18 installed. The write from user2 is successful. You should never get a locked record status on a write statement. Even if the record already exists and it is locked it should return an invalid key condition file status 22.
Which product and version number are you using?
Are you setting any file configuration options in an EXTFH.CFG file?
I cannot reproduce the problem that you report.
Do you have any updates applied to the 5.1 base release? If you look in the Net Express Help under About what is the full version number that is displayed?
Under what operating system is the application running?
Where does the indexed file reside? Is this on the local system to which users are logging in or is it on a network drive accessible as a share?
I would recommend that if you have a current maintenance contract with Micro Focus that you open up a support incident with Customer Support. We will most likely need a small repro program that demonstrates the issue so we can run it in-house.
First of alI i really do appreciate your follow-up and support.
Netexpress 5.1 version 5.105.0076
the applications running as client server application: the server running under Windows Server 2012 R2 Standard ver .using Flexus product ((Thin Client application)), all data and applications installed in the server side, nothing reside on the client except some dlls belongs to Flexus Thin client to connect to the Server
Client Pcs running under Windows 10 and 7.
Unfortunately, I don’t have a valid current maintenance to open a, support incident
I’ve used sharing files and locks quite many, but I didn’t face this issue, I may have done something not correct, I will review and trace my codes,, but if you have a sample program creating and updating indexed-file using sharing file with locking and unlock, I will take as a guide to me to review my source.