Skip to main content

Problem:

On versions post 2.2 of Server Express this error may occur when trying to create an indexed file from a line sequential file maintaining the record format defined in the previous file.

The loader is a C program which includes an FCD structure with the FCD3 format and a

code which sets the value of the FCD field - all set to OPEN OUTPUT and DYNAMIC ACCESS MODE.

If the not-ordered key is encountered, the following error is returned:

write error: status = 2/1

So is it possible to create an Micro Focus indexed file from a sequential file containing the record including the keys but not in ascending order?

Resolution:

In earlier releases of the product the sequence checking was performed on the basis of the K switch.  However, at some stage in the life-cycle of the product, it was changed so that this would have to be sent via a tunable.

The value used in the access mode byte of the FCD specifies only that this FCD uses a file status. It does not specify access dynamic so the 2/1 error is expected when inserting keys which are out of order.

To resolve this, either modify the C program to specify access dynamic, 0x88, or make use of the File Handler configuration option NOSEQCHECK.

Old KB# 2229

#ServerExpress
#AcuCobol
#netexpress
#COBOL
#RMCOBOL