SYSTEM
Names the Transact program and any databases, files, or forms files that
are used by the program.
Syntax
SYSTEM program-name[,definition-list];
The SYSTEM statement names the program and describes databases, files, or
forms files that the program uses. It overrides the default space
allocations that Transact uses. It must be the first statement in the
program.
Statement Parts
program-name A 1 to 6 character string of letters or digits that
names the program. Transact stores the output from
the compiler in a file called "IPxxxxxx" where
"xxxxxx" is the program name. program-name is also
used to call up the program for execution when the
user enters it in response to Transact/V's SYSTEM
NAME> prompt.
definition-list Description of the files or data sets used during
execution. Each definition list describes a file.
Within the definition list, the fields can be in
any order and separated by commas.
BANNER "text" Causes the text string to be
placed at the top left
position on every page of
line printer output generated
during execution of the
program.
BASE=base-name1[(["password"][,[mode]
[,[optlock][,[basetype]]]])]
[,base-name2[(["password"][,[mode]
[,[optlock][,[basetype]]]]])]]...''
base-name The name of a database used in the
program. This database has the
attributes described in the
TurboIMAGE/V or XL Database
Management System Reference
Manual. The base-name1 is termed
the home base and any references
in the program to this database
must not include a base qualifier.
The name of the home base is
stored in the system variable
$HOME.
The BASE description opens the
database. The home base can be
opened a second time by repeating
its name in the database list in
the SYSTEM statement. This
feature allows two independent and
concurrent access paths to the
same detail set without losing
path position in either access.
This might be necessary for a
secondary access of a detail set
during processing of a primary
access path in the same data set.
References to data sets in bases
other than the home base must be
qualified by including the name of
the database in parentheses
following the data set name:
set-name(base-name)
If one or more of the following
three qualifiers are used, they
must all be enclosed in
parentheses.
base-type The floating-point type
specification for the database.
The valid types are HP3000_16 and
HP3000_32.
HP3000_16 specifies that the file
requires HP floating point format.
HP3000_32 specifies that the file
requires IEEE floating point
format. If no type is specified,
HP3000_16 is assumed.
password Used by Transact for opening the
database. If no password is
provided, at execution time
Transact prompts with
PASSWORD FOR base-name>
If the user enters an incorrect
password, Transact issues an error
message and then prompts again for
the password.
For Transact/iX, up to three
password prompts are issued. If
the password is still invalid, the
program will end. In batch mode
for both Transact/V and
Transact/iX, if the password is
invalid on the first response, the
batch job ends.
mode Used by Transact for opening the
database. For Transact/V, this
specification overrides any mode
given by the user at execution
time in response to the SYSTEM
NAME> prompt. For Transact/iX,
this specification overrides a
mode specified by the TRANDBMODE
environment variable. The default
is 1.
If dynamic transactions are being
performed (Transact/iX only),
DBOPEN mode 2 cannot be used.
For more information about access
modes, see "Database Access" in
Chapter 5.
For example, to specify the
database STORE to be opened with
the password "MANAGER" in mode 1:
SYSTEM MYPROG,
BASESTORE("MANAGER",1);
optlock Specifies whether or not optimized
database locking is to be used.
It can be a value of 0 or 1. The
default = 0. (See Chapter 6 for
more details.)
0 Tells Transact to always
lock unconditionally at
the database level.
1 Tells Transact to lock
conditionally at the
optimum level which avoids
a deadlock with other
Transact programs.
DATA=data-length, data-count
data-length The maximum 16-bit word size of
the data register. The
DATA=data-length specifications
given in a main program
establish the maximum data
register size used by all
called programs and take
precedence over any
DATA=data-length specifications
in called programs. The
default is 1024 16-bit words.
data-count The maximum number of items
allowed in the list register.
The DATA=data-count
specifications given in a main
program do not establish the
number of entries in the list
register used by all called
programs nor does it take
precedence over any
"DATA=,data-count"
specifications in called
programs. Default=256 items.
FILE=file-name1
[([access][(file-option-list)]
[,[record-length][,[blocking-factor]
[,[file-size][,[extents][,[initial-allocation]
[,[file-code]]]]]]])]
[,file-name2...]...
file-name The MPE file name assigned or
to be assigned to the file. A
back-referenced file name using
a leading "*" is permitted.
access One of the following access
modes:. READ, WRITE, SAVE,
APPEND, R/W (read/write),
UPDATE, SORT. SORT is identical
to UPDATE with the additional
SORT capability. In other
words, an end-of-file is
automatically written into the
file before the SORT, and the
file is rewound following the
SORT. It is recommended that
you generally use UPDATE rather
than READ or WRITE as this
access is required to use
either the REPLACE or UPDATE
statements. The default is
READ.
Any of the following fields
file-option-list provided that they do not
conflict in meaning: Any of
the following fields provided
that they do not conflict in
meaning:Any of the following
fields provided that they do
not conflict in meaning: OLD,
NEW, TEMP, $STDLIST, $NEWPASS,
$OLDPASS, $STDIN, $STDINDX,
$NULL, ASCII, CCTL, SHARE,
LOCK, NOFILE, HP3000_16,
HP3000_32. (See FOPEN in MPE
or MPE/iX Intrinsics Manual for
a detailed explanation of these
options and terms.)
The default is OLD (old file),
binary, no carriage control,
and file equation permitted.
A temporary MPE file defined
for WRITE access with the
option TEMP is purged when
Transact exits if Transact
automatically opens and closes
the file. However, it is not
purged when Transact exits if
the CLOSE verb is used
programmatically. It is purged
immediately whenever the
FILE(CLOSE) verb is used.
HP3000_16 specifies that the
file requires HP floating point
format. HP3000_32 specifies
that the file requires IEEE
floating point format. If
neither HP3000_16 or HP3000_32
is specified, HP3000_16 is
assumed.
record-length Record length of records in
file. A positive value
indicates words, a negative
value indicates bytes. Default
is byte length required by file
operation.
Blocking factor used to block
blocking-factor records. The default is 1
record/block.
file-size Size of the file in records.
The default is 10000 records.
extents Number of extents used by the
file. The default is 10
extents.
Initial allocation of extents.
initial-allocation The default is 1 extent.
file-code MPE file code for the file.
The default is 0.
For example, to define a file
with Read/Write access, 40
words per record, a blocking
factor of 3 records per block,
and a file size of 100 records:
SYSTEM FREC,
FILEWORK(R/W,40,3,100);
In an MPE file or a KSAM file,
you can then define the entire
record as a parent item, and
define individual fields as
child items. This allows you
to access the entire record by
its parent name, and also refer
to individual fields. For
example:
DEFINE(ITEM) RECORD X(80):
ITEM1 X(25) = RECORD(1):
ITEM2 X(30) = RECORD(26):
ITEM3 X(15) = RECORD(56):
ITEM4 X(10) = RECORD(71);
LIST RECORD;
GET(SERIAL) WORK,
LIST=(RECORD);
DISPLAY ITEM1: ITEM2: ITEM3: ITEM4;
DATA(SET) ITEM1: ITEM2: ITEM3: ITEM4;
:
FSTORESIZE=formstoresize
formstoresize The number of forms allowed to
be stored in the terminal,
specified as a number from -1
to 255. The 2626A terminal can
store up to four forms. The
forms directory on the 2624B
can contain up to 255 depending
on the form size, the type of
datacomm network, and the
memory capacity of the
individual terminal.
If formstoresize is 0 to 255,
VPLUS automatically configures
the 2626A and 2626W terminals
to use datacomm port 1 and
removes the HPWORD
configuration from the 2626W
terminal.
If 0 is specified, local form
storage is not performed.
VPLUS configures the 2626A and
2626W terminals as explained
above.
If -1 is specified, no local
form storage is performed.
VPLUS does not change any
terminal configuration, and
either terminal port can be
used.
If the FSTORESIZE parameter is
not specified, the
FORM'STOR'SIZE field in the
VPLUS comarea is set to -1, so
that no local form storage is
performed. VPLUS does not
change any terminal
configuration, and either
terminal port can be used. See
"Local Form Storage" in Chapter
5 for more information.
KSAM=file-name1 [(access [(file-option-list])]
[,file-name2 ...]
file-name Name of a KSAM data file.
access One of the following access
modes: READ, WRITE, R/W,
(read/write), UPDATE, SAVE,
APPEND. The default is READ.
Any of the following fields
file-option-list provided that they do not
conflict in meaning: OLD,
$STDLIST, $NEWPASS, $OLDPASS,
$STDIN, $STDINDX, $NULL, ASCII,
CCTL, SHARE, LOCK, NOFILE. (See
FOPEN in the KSAM/3000
Reference Manual for a detailed
explanation of these options
and terms.)
Defaults are OLD (old file),
binary, no carriage control,
and file equation permitted.
OPTION= option For Transact/V, either enable
or disable the test facility
for this program execution;
option can be either one of the
following:
TEST Enables the TEST
facility during
execution of the
Transact/V program.
NOTEST Disables the TEST
facility during
execution of the
Transact/V program.
The default is TEST.
This option is ignored by
Transact/iX.
SIGNON= "text" Causes the text string to be
displayed as a sign on message
each time the program is
executed. For example:
SYSTEM MYPROG,
SIGNON="Test Version of MYPROG A02.31"
SORT= number Specifies the number of records
in the sort file. The default
is 10,000.
VPLS=file-name1[(form-name1[(item-list1)]...)]...
[,file-name2[(...)]...]...
file-name The name of a VPLUS forms file
that is used in the program.
Every forms file referenced in
a Transact program must be
specified in the SYSTEM
statement.
form-name The name of a form defined
within the VPLUS forms file.
If omitted, the dictionary
definitions of all the forms in
the specified forms file are
used.
For example, if forms file
CUSTFORM has a dictionary
definition, you can specify:
SYSTEM MYPROG,
VPLS=CUSTFORM;
If not, you must name each form
in the forms file. For
example, assuming CUSTFORM has
three forms, MENU, FORM1, and
FORM2; MENU has no fields,
FORM1 has 3 fields, and FORM2
has 4 fields:
SYSTEM MYPROG,
VPLS=CUSTFORM(MENU(),
FORM1(F1,F2,F3),
FORM2(F4,F5,F6,F7));
item-list A list of item names used in
the program, in the order in
which they appear on the VPLUS
form, which is in a left to
right and top to bottom
direction. The names need not
be the same as the names
specified for the fields by
FORMSPEC, but the items must
have the same display lengths
as the fields. If omitted, the
dictionary definitions of all
the fields in the specified
form are used.
For example, suppose the fields
in FORM2 are defined in the
dictionary:
SYSTEM MYPROG,
VPLS=CUSTFORM
(MENU(),
FORM1(F1,F2,F3),
FORM2);
WORK=work-length, work-count
work-length The maximum 16-bit word size of
the work area containing the
match, update, and input
registers. This work area is
used by Transact/V to set up
temporary values used during
execution of the program. The
default is 256. Transact/iX
automatically allocates enough
room for all temporary
variables, so the work-length
option has no affect on a
Transact/iX program.
work-count The maximum number of entries
allowed in the work area for
Transact/V. The default is 64.
Transact/iX automatically
allocates entries for the work
area, so work-count has no
effect on a Transact/iX
program.
WORKFILE=number Specifies the number of records
in the work file. The default
is 10,000 records. This option
replaces the SORT=number option
which remains available for
backward compatibility.