Product Documentation

FairCom ISAM for C

Previous Topic

Next Topic

More About File Modes

Transaction Mode

The following file modes are related to transaction mode:

  • ctPREIMG
  • ctTRNLOG
  • ctLOGIDX

With the FairCom Server or single-user mode you can specify the method of transaction management for a file. Transaction management is discussed in more detail in Data Integrity. ctLOGIDX should only be applied to index files, not data files.

Mirroring Skip Mode

The following file mode is related to mirroring skip mode:

  • ctMIRROR_SKP

With the FairCom Server or Single User mode, it is possible to disable mirroring at an individual file level using the ctMIRROR_SKP file mode. See Data Integrity for details.

Resources

The following file mode is related to resources:

  • ctDISABLERES

Resources are special variable-length records used to store information in a data file that are not in the same format as the regular data records. Normally they are enabled, but under certain circumstances, you may want to disable them. See Resources for further details.

Superfiles

The following file mode is related to superfiles:

  • ctSUPERFILE

A Superfile is a c-tree file that may contain an arbitrary number of c-tree data and index files. This permits a group of files to be moved or copied as a single physical unit. This minimizes dependency on system file descriptors and simplifies file administration. See Superfiles in this manual for further details.

This file mode should not be applied to index files. When a data file is placed in a superfile, all associated index files are placed in the superfile automatically.

Corrupt Files

The following file mode is related to corrupt files:

  • ctOPENCRPT

As discussed in detail in File Recovery, each data and index file has a header record. If the header record is compromised, you will not be able to open the file successfully. Typically, you will receive an error code of FCRP_ERR (14). Use RebuildIFile() to rebuild the compromised data file and index.

There are, however, some instances when you want to be able to open a file that has been corrupted. For instance, to use DeleteCtFile() to get rid of the damaged file.

c-tree provides a file mode of ctOPENCRPT for this purpose. If you OR in this mode when you open the file, you will be able to bypass the normal error checking done by c-tree.

Warning: Do not use ctOPENCRPT except in those rare cases requiring it and only for the purpose of deleting the file or doing some very low level processing.

We cannot guarantee the success of any c-tree function other than DeleteCtFile() if you use this mode. Extensive processing of a corrupted file may result in serious problems

TOCIndex