Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

USER COUNT: -1 1

Status
Not open for further replies.

harrelld

MIS
May 9, 2002
7
0
0
US
NEWBIE TO COBOL: I have a file that becomes corrupted whenever two users try to update simultaneously. I did a
[VUTIL -INFO (filename)]
It returns
USER COUNT: -1
Does this mean anything? Because it keeps on working,
doesn't make it right.
 

Here is what the manual says about the user count. I have never seen a negative user count myself but it sounds like there might be a problem with the runtime. Have you talked to Acucorp about it?

Ted




A value of note is the "user count". This value starts at zero, and is incremented each time the file is opened for I/O. This number is decremented when the file is subsequently closed. Under normal circumstances, the user count indicates the number of users who are currently updating the file. Should runcbl die suddenly, then this number will not be decremented. Thus, if the user counter is ever non-zero when there are no users active, then it indicates a sudden program failure and suggests that corrective action may need to be taken. At the very least, the file should be checked for integrity, but depending on the program that died, perhaps more significant action should be taken.

Basically a non-zero user count indicates that someone knowledgeable about the system should intervene and ensure that everything is okay. This can be used as an early warning system to head off some problems before they surface in a more serious form. Note that under normal operation, a COBOL coding error will not cause this condition to occur, because runcbl will usually close all of its files when it detects an error.

 
Thank you Ted.
I have not talked with AcuCorp about this problem.
Last night I rebuilt the file using
[VUTIL -rebuild (filename)] with no effect on the user count. I shut the server down for the entire night, booted the server up this morning (no effect) rebuilt the file again and this time it did reset to 0. Interesting note I found that the FATB.INX file is currently showing a user count of 51. When I tried to rebuild it I get an [Access denied error]. Next step calling AcuCorp.
Thanks again Ted. Because it keeps on working,
doesn't make it right.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top