File Specifiers and Modifiers
File Specifiers
A filename implies two logical files: a dictionary section and an associated data section. The data section contains the data that is usually retrieved or referenced. The dictionary section contains definition items, such as data section definition items, data definition items (previously known as attribute definition items), and macro definition items. File and Data Definition Items, Conversion Codes and Macros describe the contents of dictionaries.
The filename must either be present in the Master Dictionary (MD) of the account from which the command is executed, as a D-pointer or Q-pointer (synonym), or the account on which the file is defined must be specified as shown below.
File Modifiers
File modifiers DICT, ONLY, WITHIN and TAPE modify how the file is accessed or used, as described below.
Syntax
{DICT} {ONLY} {WITHIN} {TAPE} {/account/}filename{,data-section-name}
Syntax Elements
DICT Specifies that the dictionary section of the file contains the data to be referenced. You can type the modifier DICT before the filename or following all clauses that contain attribute names. When DICT is used the processor looks in the MD for attribute and macro definition items.
ONLY Specifies that only the item-ids are to be output and any default output specification is to be suppressed. You can type the modifier ONLY before filename or following all clauses that contain attribute names.
WITHIN Specifies a sublist such as bill of materials items. WITHIN can only be
used with the
LIST and
COUNT commands and must precede filename. One item-id
must be specified. If more than one
TAPE Tells the processor to retrieve the data from magnetic tape. The data must have been written to tape in T-DUMP format. You cannot use this modifier with the sorting commands, such as SORT, nor with the updating command EDELETE.
FMT Allows any or all of the column header, justification & width to be altered.
/account/ Specifies the account on which the file is defined.
filename Specifies a dictionary section and a data section.
data-section-name
Specifies a data section other than the data section called filename. If specified, it must follow filename after a comma
but no spaces.
Default to Master Dictionary
When the processor does not find a data or macro definition item in the dictionary section (or in the file specified in a USING clause), it will use any corresponding item in the account's Master Dictionary.
Example
Your account has a file for customer data. The name of the file is CUSTOMERS, that is, there is a dictionary section named CUSTOMERS, which points to a data section named CUSTOMERS. At the end of 1993 you renamed the data section from CUSTOMERS to 93 by means of the command:
:RENAME-FILE CUSTOMERS,CUSTOMERSTO:93
Using the CREATE-FILE command, you created a new data section named CUSTOMERS:
:CREATE-FILE CUSTOMERS,CUSTOMERS 113,1
CUSTOMERS now contains data for your current customers, and 93 has the data for your customers in 1993. When you want to sort the current data, you type
:SORT CUSTOMERS
When you want to sort the data from 1993, you type
:SORT CUSTOMERS,93
For convenience you create a Q-pointer in the master dictionary:
CUST.93
001: Q
002:
003: CUSTOMERS,93
You may now sort the 1993 data by typing
:SORT CUST.93
The file name CUST.93 identifies data section 93 of file CUSTOMERS.