Syntax
$insert.suffix
What it is used for?
This unique Envision operator allows you to specify insert modules that will be used by the current process and that can be shared among processes.
The dollar sign ($) operator is valid for all field hooks, as well as for all process level hooks.
When used in the Input Source field hook, the Envision generator searches the application.INSERTS file for an insert module prefixed “I_ACCEPT.” and suffixed with the insert.suffix.
For example, if the Input Source hook contains the following:
$SPECIAL.FIELD.INPUT
…then the generator first looks in the application.INSERTS file for I_ACCEPT.SPECIAL.FIELD.INPUT.
The generator next searches the application’s tree for the insert module, ending with the utility application, UT.
The generator examines the application.tree.INSERTS file.
If not found, the generator assumes the insert is in the application.SOURCE file.
If the insert module does not exist in the application.SOURCE file, the generated program will not compile.
NOTE: If the Input Source field hook contains any code at all, the default input processing provided by the generator will not take place. If this process field requires input from the user, your Input Source code should include a section to get input from the user and load that input into the variable INPUT.DATA.
Most operating systems have an upper limit on the number of characters used to name a record in a file.
Since the dollar sign Envision operator will preface the insert module name with a standard string, be sure that the insert suffix name, when concatenated with the standard prefix, does not exceed the operating system’s limitation on record names.
When this operator is used in the Input Editing field hook, the Envision generator searches the application.INSERTS file for an insert module prefixed “I_INPUT.” and suffixed with the insert.suffix.
For example, if the Input Editing hook contains the following:
$FIELD.VERIFICATION
then the generator will first look in the application’s INSERTS file for I_INPUT.FIELD.VERIFICATION.
The generator next searches the application’s tree for the insert module, ending with the utility application, UT.
The generator examines the application.tree.INSERTS file. If not found, the generator assumes the insert is in the application.SOURCE file.
If the insert module does not exist in the application’s SOURCE file, the general program will not compile.
NOTE: This post is from the book Envision Basic Command Reference.
basics examples INSERT operators