Special Characters and Keys That Control Execution [ HP Transact Reference Manual ] MPE/iX 5.0 Documentation
HP Transact Reference Manual
Special Characters and Keys That Control Execution
Several categories of special characters and keys lend programmers and
users powerful control over Transact's program execution. These
characters and keys include:
* Ctrl Y
* Data entry control characters
* Match specification characters
* Field delimiters
* Special keys for use with VPLUS forms
Control Y
Transact recognizes Ctrl Y entered from the user terminal as an operation
break that returns control to Transact.
You can use the Ctrl Y feature to halt program execution temporarily in
order to enter a TEST or COMMAND command. After using either of these
commands, you can continue execution by entering the command RESUME. This
feature is especially useful during Transact/V program debugging. For
example, you can enter the command TEST followed by a test-mode parameter
when the program is temporarily halted. When you resume execution, the
program executes in the specified test mode. (See Chapter 10 for a
description of the test facility.)
Data Entry Control Characters
Several special characters have a predetermined meaning to Transact.
They should not be used in any other way as a response to a data entry
prompt. They include the following:
] Terminates the current operation. Control passes to the
next higher processing level, which can be the command
level.
]] Terminates the current operation. Control passes to
command level.
! Generates null responses for all subsequent prompts when
entered as a response to a data item prompt. It generates
null responses for all subsequent sub-item prompts within a
compound item when entered as a response to a compound item
prompt.
In a command sequence, the effect of the ! response is terminated by the
end of the command sequence; if the prompt is not in a command sequence,
the ! response remains in effect for all subsequent prompts up to the
beginning of a command sequence, if any. The effect of the ! response
is also terminated if control passes again through the statement to which
the end user responded with !. And, Transact terminates the effect of
the ! when it performs automatic error handling.
MATCH Specification Characters
Several special characters help to set up match specifications and are
used in response to prompts issued by PROMPT(MATCH) and DATA(MATCH)
statements. Because of their special meaning, these characters should
only be used for these purposes in character strings. They include the
following:
Single Caret(^) Indicates a partial-word selection criterion for
alphanumeric string data items.
* If "^" is the last character of the entry, then
the selection is based on a search for database
or data item values that start with the preceding
character string.
For example, when the user enters "DE^" in
response to a prompt generated by a PROMPT(MATCH)
statement, all values starting with the
characters "DE" in a subsequent database or file
operation are selected.
* If "^" is the first character of the entry and it
does not occur at the end of the string, then
values that end with the input string are
selected.
For example, "^DE" would retrieve all data item
values that end with the characters "DE".
* If the "^" character appears in any other
position in the entry, values are selected that
have any character in this position.
For example, an entry of "^EF^G^" causes a
selection of all values having "EF" in the second
and third positions and "G" in the fifth
position.
Double Caret Indicates another partial-word selection criterion for
(^^) alphanumeric string data items. When the user enters
"^^" as the trailing characters in an entry, the
selection is based on a search for database or file data
item values that contain the preceding character string
anywhere within them. For example, an entry of "DE^^"
causes a selection of all data item values that contain
"DE" in any location.
Field Delimiters
Two characters are used as field delimiters for data entry. They cannot
be used as part of an input string unless the field delimiter characters
have been suppressed or modified by the SET(DELIMITER) statement. These
field delimiters are the comma (,) and the equals sign (=).
If you want to use these characters as is, not as delimiters, you can do
one of two things: You can enclose text or responses containing these
delimiters within quotes, or you can use a SET(DELIMITER) statement to
change Transact's default delimiters to some other character.
Blanks are not normally treated as delimiters; leading and trailing
blanks are stripped from responses unless they are enclosed in quotes.
You can also use the BLANKS option with data entry verbs (DATA, INPUT,
and PROMPT) to allow leading blanks to be included in a response.
Whatever the delimiter, delimiters can be very useful for responding to
prompts. When the user knows the prompt sequence for a particular
operation, then he or she does not have to wait for prompts, but can
enter a string of data fields separated by delimiters. Transact takes
the appropriate action. For example, assuming the default delimiter,
suppose a user responds as follows to the command prompt:
>ADD TIME-SHEET = SMITH,77,3,2,V10400,100,....
In this example, Transact recognizes the "," and "=" as delimiters, and
associates each response with the sequence of prompts that would normally
be issued by the ADD TIME-SHEET command.
Special Keys for Use with VPLUS Forms
Certain special keys can be used while processing VPLUS forms sequences:
Enter When used in a GET(FORM) operation: Normal edit
processing as defined in the VPLUS form definition is
executed, and the data is transferred to the data
register. Control passes to the next statement in
the program.
When used in a PUT(FORM) operation with a WAIT=
option: control passes to the next statement in the
program.
f1 to f7 Control passes to the next statement in the sequence.
f8 Control returns to command level unless there are no
commands to execute, in which case the EXIT/RESTART>
prompt is issued.
This is the default action caused by these keys; this action may be
overridden by using the FKEY= or the Fn= options with verbs that use the
FORM modifier.
MPE/iX 5.0 Documentation