APPX Software Library

Section 4: Data Dictionary - Files

Data Dictionary - Files

Item 4.1

Conversion Bug (flagged in V05): A SP2 memory file created upon first use (i.e., location type 2 with creation type 1) is converted to an APPX disk/permanent file (although the APPX file does not show up in File Selection or File Specifications in Database Management). To correct, try changing the APPX file to memory, then back to disk, and finally back to memory (however, see item 4.2). It might be wise to check how the file is defined in APPX since there are hidden fields being maintained. To do this, run the APPX Software, Inc. UTL CS utility "APPX FILE File List".

Item 4.2

Bug?: In certain cases the use of a memory file can cause problems in APPX. For example, sometimes a job using a memory file will not run to completion in background. Although many problems related to memory files have been fixed, there are still some unresolved issues. You might consider converting the file to disk if it will be used in any critical functions such as posting or updating. However, this may not be a total fix since the problem may be related to sharing issues with 'Separate Task OK?'="Y".

Item 4.3

Bug (FYI): In APPX 1.8.4, if a file exists for a database currently sharing another database's file (via Use Database) and the shared file is restructured, "restructure required" error messages may be encountered unless any existing file is also restructured (by temporarily removing the Use Database value). Note that these unused files may be left-over from SP2 or may have been created to avoid the APPX bug on IF EXIST for a shared file (described in item 8.3). (See item 2.8 to identify SP2 shared files.)

Item 4.4

Bug (Pete to fix in 3.1?)(flagged in V05): In APPX 2.x (thru APPX 3.0.0): Default Value is not editable or visible for TEXT fields/domains or for fields with Field Type DOMAIN referencing domains with Type FORMAT, raising questions as to whether the SP2 default value was preserved in the conversion or whether it will be honored. To view the default value (also called 'Init') which will be used at runtime, run the APPX Software, Inc. UTL CS utility "APPX ELEMENT File Detail List" and enter the field name as the element name. If necessary, add code to set the default value in Start of Process for any process referencing the field. (Default Value was editable in APPX 1.8.4.) (See item 5.11.)

Item 4.5

Conversion Bug: Synonyms of concatenated fields in SP2 are converted to be synonyms of group headers in APPX. Such synonyms are not allowed in APPX and cause an error when processing the DD. Change these synonyms to be group headers instead.

Item 4.6

Conversion Bug (fixed in V05): Root fields of domains within the same application lose their documentation in the conversion since the documentation is tied to the domain, not the root field. To allow access to this documentation, set the 'Use Domain Doc?' flag to "Y".

Item 4.7

Bug (flagged in V05): In APPX 1.8.4 (thru APPX 3.0.0), if a field with Read Security is defined on an output or inquiry image and a DISPLAY command is given on that field, a user without the required security rights will get APPX system error RMUPD.C.156 ("upd_chr - characteristic doesn't fit on image"). In APPX 3.0.0, if the DISPLAY command is removed, the function works properly. This bug does not affect inputs nor does it affect users with the required security. (See items 5.1 & 10.1.)

Item 4.8

Conversion Bug (flagged in V05): Record protection fields used for delete protection, key protection, and record access security are identified in the file header in APPX, not defined in the individual fields as in SP2. However, Record Protection Fields may not be set when appropriate in the conversion, particularly when the fields in question are based on domains, and should be checked. (See items 1.56, 4.9, & 4.10 too.)

Item 4.9

Bug (FYI): In APPX 2.3, if Record Protection Fields are edited on the file header, APPX may improperly default these field names when the Record Protection pop-up box is accessed for another file with no record protection fields.

Item 4.10

Bug (FYI): In APPX 2.3, if the Toolbox utility Renumber Fields is used after adding fields and the seq# of a delete/key/record protection field is changed, the Record Protection field names in the file header reflect the wrong fields.

Item 4.11

Bug: The Format column may not properly show Tbl even though a Validation Table exists for fields with Field Type FORMAT (and possibly Type ALPHA). Note that a pg printout of file TOKEN in Portdata lists all fields that should have validation tables. Nothing works to force the display of 'Tbl' but it does not seem to cause a problem.

Conversion Bug (fixed in Version 04): Version 02 of the conversion utility can create TOKEN records with token type '1' in the first byte. Token type must be '0' for validation tables converted from SP2 to work properly.

Item 4.12

Difference (flagged in V05): SP2 allows 79 characters for Default Value and Edit Mask whereas APPX only allows 60 characters. In the case of Edit Mask, this is a critical difference since Edit Mask is used to size the field and must match SP2. Address problem fields (see item 2.16).

Item 4.13

Note (FYI): Be sure to exit and reenter APPX after making any changes that involve Tbl formats (such as validation tables and TOKEN fields); otherwise, the changes will not take effect.

Item 4.14

Note (FYI): The AA option flags indicating the presence of non-default Additional Attributes may be improperly set after conversion. These are not necessarily corrected by Synchronize Design Elements which doesn't always follow the same rules as the Editor. (Most flags can be cleared by stepping thru the option or by making a temporary change.)

Item 4.15

Note (FYI): Fields based on domains with a validation table do not indicate this since the validation table is only accessible (or visible) via the domain.

Item 4.16

Note (Bug fixed): Root fields of domains with Data Lookup now appear to work OK if left as Field Type DOMAIN. (In earlier versions, it caused problems at runtime if the root field had a Data Lookup to itself.)

Item 4.17

Note (Bug fixed): Fields with Field Type SYSTEM appear to convert correctly now. (In earlier versions, Format did not show properly for Date Add, User Add, Date Chg, and User Chg.)

Item 4.18

Note (FYI): If nothing else works to overcome problems caused by Field Type DOMAIN, change the field type to not be a domain.

Item 4.19

Bug (fixed in V05): If Conversion Utility 2.00 Version 04 dated 11/10/94 is used to convert to APPX 2.x and higher (at least thru APPX 3.0 Beta), field descriptions, column headings, and default values will be lost for non-domain fields. To avoid this problem, you must use vi (before running convert.sh and before importing) to delete records in file DOMAIN in Portdata that have 'Generated?' flag "Y" in the first byte. Since this flag is part of the key, all records for real domains (which have 'Generated?' flag "N") appear first. You can precede the dd command in vi with the number of lines (records) to delete.

Item 4.20

Action/Difference (between the VS and UNIX): The V05 conversion utility provides a description of all files defined in the application on the File conversion log. Consecutive/permanent files should be checked for file transfer usage to see if a field for record delimiter is needed. Use the APPX Software, Inc. UTL CS utility "APPX FILE File List" to list them by entering File Organization "2" and 'Temporary File?' value "N" as job specs. Investigate any file which has all fields defined as ALPHA. If a UNIX file is to be transferred to a PC diskette or to tape, a HEX(0A) record delimiter may be needed to allow the file transfer program to recognize the record length (unless the file has fixed length records and the file transfer program can handle that). Most file transfer programs expect HEX(0A) as the standard UNIX record delimiter and HEX(0D0A) as the standard PC record delimiter and provide for this conversion. The VS does not need a record delimiter field.

To set the value of HEX(0A) in a one-byte alpha field, use the following code:

CNV BIN  aaa alpha field                =      10

To set the value of HEX(0D) in a one-byte alpha field, use the following code:

CNV BIN  aaa alpha field                =      13

Item 4.21

Action: Check APPX for format missing in Format column and determine cause if not legitimate. The APPX Software, Inc. UTL utilities "APPX DOMAIN File List" and "APPX FIELD File List" provide a warning whenever format is missing in error. (See item 3.5.)

Item 4.22

Conversion Bug?/Note: The conversion utility does not flag some conditions which cause errors when processing the data dictionary in APPX. For example, 'Groups Overlap' errors are not caught. These can be addressed by moving one group header to the end of the file and using synonyms for its components. Note that clearing up 'Groups Overlap' errors often eliminates other error messages as well (such as "Invalid 'Group Through' Field on Group Header").

Item 4.23

Conversion Bug (fixed in V05): SP2 fields defined as 'Same As' with 'Copy Doc?'="Y" are converted with 'Use Domain Doc?'="N". It should be "Y". Note that SP2 Tech Doc does not show the 'Copy Doc?' flag. (See item 5.10.)

Item 4.24

Difference: Since APPX may display question marks for unsigned numeric fields with negative values where SP2 would show the negative value, you may want to investigate any critical unsigned numeric field with the potential to go negative. The best way to find such fields is to look at the field format column in the APPX Data Dictionary for formats starting with "9(" or to search APPX File Tech Doc on the screen for "m 9(" (to allow for numeric fields based on domains). Mark these fields on the SP2 File Tech Doc and address as needed. (See items 2.11, 5.12, 9.30, & 10.19.)

However, it is probably not practical to address the question marks since this is supposed to be corrected in a future release of APPX.

Item 4.25

Difference (flagged in V05): Since "PF" terminology is not applicable in APPX, modify "PF" text as appropriate. (See item 2.14.)

Item 4.26

Difference/Conversion Bug (flagged in V05): SP2 allows invalid characters in the Input Mask and APPX does not. (See item 3.8.)

Item 4.27

Note (FYI): According to Korry, in determining whether to preserve the contents of a field, APPX first looks for a matching field name. If that fails, APPX then looks for a matching date/time stamp for when the field was added. This technique allows the field name to be changed without losing data.

Item 4.28

Note (FYI): If a file that needs restructuring is selected for Rebuild Key Files, the message "Key File Not Rebuilt, file/path not found" may appear.

Item 4.29

Bug (FYI): APPX 1.8.4 may sometimes require that a data file be restructured or a structure file be rebuilt after seemingly innocent changes are made in the Data Dictionary.

Item 4.30

Action/Difference: SP2 allows the use of some special characters in the file name whereas APPX does not. Also, SP2 allows a file to be defined in the Data Dictionary with a blank file description whereas APPX does not. The APPX Software, Inc. UTL CS utility "APPX FILE File List" will provide an error message if the file name is invalid and will provide a count of files with blank descriptions.

Item 4.31

Action/Bug/Difference: SP2 allows a file to have an alternate key of up to 255 bytes. For a non-unique alternate key, APPX 3.0 requires that the alternate key PLUS the primary key be <= 255 bytes. Otherwise, this can cause an APPX system error at runtime (at Pinellas a runtime system error occurred after changing data on the screen in CHANGE mode of an input process where the PCF file had an alternate key over 255 bytes). The APPX Software, Inc. UTL CS utility "APPX FILE File List" will print a warning message if the primary key plus any alternate key exceeds 255 bytes. If the alternate key is non-unique, the key must be shortened to avoid errors.

Item 4.32

Action/Bug?/Difference: The file access method used by APPX may impose stricter requirements for valid key structures than SP2 did. This can result in invalid key number errors during Create Files and Restructure Files even though the Data Dictionary processes with no errors. These requirements affect only disk files, not memory files.

If APPX is using its own proprietary file access method (called UNIX I/O), invalid key number errors can be caused by the following conditions:

  1. There are more than 16 segments (fields) in the primary key.
  2. There are more than 16 segments in any alternate key plus the primary key.
  3. There are more than 15 alternate keys (this limit may be an APPX bug --16 alternate keys may be the actual limit).

The APPX Software, Inc. UTL CS utility "APPX FILE File List" will print error/warning messages as applicable for files found to have any of these conditions.

CAUTION: It may become necessary to redefine fields as substring fields in order to reduce the number of segments in a key. If so, use Design Transfer to make a copy of the file under another name before such modifications (perhaps renaming it with a "Z" in the first byte of the file name). Remove all keys from the "Z" file and change it to be a consecutive file. This file will be needed to import data for the file from the VS (be sure the name of the SP2 exported file in Portdata reflects the "Z" name before importing). Once imported, an update function can be used to transfer the data to the live file.

Also, beware of redefining FORMAT fields to be SUBSTRING fields since APPX will not enforce format requirements on fields that are substrings of FORMAT fields. Other editing that was inherent to the field definition may have to be programmed with commands instead.