ContentsIndexPreviousNext

2.1.4 File Options

Some file options (-Fx, -Fxa, and -Fx3) are used to generate XFD files (data dictionaries) that are used with Acu4GL, with the alfred record editor, and with international character mapping for AcuODBC and AcuServer. The other file options (-Fl, -Fs, and -Ft) can simplify the addition of transaction management facilities to existing programs that use the Vision file system. For more details concerning transaction management, see Chapter 5, section 5.1, "Transaction Management." For more details about international character mapping, see section 5.4.

-Fc Using this option causes the field names in generated XFD files to match exactly the source of the COBOL program that generated them.

-Fl Enables single locking rules rather than multiple locking rules as the lock mode default. Normally, "WITH ROLLBACK" causes multiple locking rules to be in effect for a file. When "-Fl" is used, the "WITH ROLLBACK" clause does not affect whether single or multiple record locking rules are followed. Single locking becomes the default. You may enable multiple locking either by specifying "WITH LOCK ON MULTIPLE RECORDS" in a file's SELECT statement or by using "APPLY LOCK-HOLDING ON file" in the I-O CONTROL paragraph.

-Fo This option must be followed (as the next separate argument) by the directory that will hold the data dictionary files generated by the compiler when you use the "-Fx" option.

Type a space after the option and then give the name of the chosen directory. If this option is not used, the data dictionaries are placed into the current directory.

For example, to cause the dictionaries to be stored in the directory "/usr/inventory/dictionaries" you would enter:

-Fo  /usr/inventory/dictionaries

-Fs Causes an implied START TRANSACTION verb before the first OPEN, CLOSE, WRITE, REWRITE, or DELETE and after each COMMIT or ROLLBACK. In effect, every file operation is part of a transaction. If this option is enabled, and the compiler encounters a START TRANSACTION verb, it reports a warning and does not generate any code for the START TRANSACTION. The "-Fs" option provides an alternate way to program transactions and is often useful when you are converting from other COBOL or SQL implementations.

-Ft Causes implied transactions for every OPEN, CLOSE, WRITE, REWRITE, or DELETE that is not part of an explicit transaction. Single file operations that are not part of a transaction are preceded by an implied START TRANSACTION and followed by an implied COMMIT. This option makes converting existing applications to a transaction system easier. Note that unlike most COMMITs, which unlock all of the file's currently locked records, the implied COMMIT does not unlock any records. See Chapter 5, section 5.1.4, "Extended Locking Rules," for details regarding file locking and the handling of implied transactions.

-Fx This option tells the compiler to build data dictionaries (XFD files) for every indexed data file in the FDs of the program. XFDs are required if you plan to use any Acu4GL interface; these interfaces cannot operate without data dictionaries. XFDs are also required for international character mapping with AcuServer and AcuODBC. XFDs also provide useful information to the alfred record editor. See also the "-Fo" compile-time option, which specifies the directory where the data dictionaries will be placed. If you use relative or sequential data files, see "-Fxa" below.

XFD files have two different formats: Version 3 and Version 4. XFD files generated with compiler Version 4.0 (and earlier compilers) have the older format: XFD Version 3. This format works with Acu4GL interfaces up through Version 4.0, and with alfred and AcuODBC versions up through Version 4.0. Unless you specify that you need the older version of XFD files (see "-Fx3" below), the compiler will generate XFD Version 4 files, which are compatible only with product versions starting with Version 4.1 and forward.

-Fxa This option tells the compiler to build data dictionaries (XFD files) for every indexed, relative, and sequential data file in the FDs of the program. It is the only option that builds XFDs for relative and sequential files. This option is used for international character mapping. See also the "-Fo" compile-time option, which specifies the directory where the data dictionaries will be placed. The "-Fxa" option generates the newest format for the XFD files (Version 4) only.

-Fx3 This option tells the compiler to build data dictionaries (XFD files) for every indexed data file in the FDs of the program. The format of the generated XFD files is XFD Version 3. This version of the XFD files is compatible with Acu4GL Version 4.0 and earlier.