CREATE PERM GROUP command

From m204wiki
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Summary

Privileges
System manager
Function
Creates a Model 204 permanent file group

Syntax

CREATE PERM GROUP groupname FROM {filename [AT location] [(OPTIONAL) | (MANDATORY)]} ,... [PARAMETER parameter[=value] [PARAMETER parameter[=value]]... . . . END

Where:

groupname The name of the permanent file group that is being created (1 to 8 characters). The group name cannot be FILE or GROUP, and it cannot start with CCA, SYS, OUT, TAPE, dollar sign ($), or percent sign (%).

The group name can contain any alphanumeric characters except those shown in the following table:

Character name Keyboard symbol
Asterisk (*)
Equal sign (=)
Left parenthesis (()
Minus sign (-)
Plus sign (+)
Right parenthesis ())
Semicolon (;)
Single quote (')
Slash (/)
Space
filename The name of a Model 204 file.

If you are specifying Parallel Query Option/204 remote files, filename must include a remote location (AT location) or be a defined file synonym. Also, do not specify multiple identifiers for the same file; that is, you cannot include two synonyms for the same file, and you cannot include a synonym and a remote file specification for the same file. A group may have up to 254 files.

location For PQO files, location is the symbolic name (as many as eight characters) that refers to the location of the node on which the remote file resides. An unquoted equal sign (=) specifies that the file is local.
OPTIONAL or MANDATORY Indicates whether PQO scattered group operations can proceed in the absence of this group member. The default is MANDATORY. Valid abbreviations are OPT and MAND.

You cannot open a group if a mandatory member is unavailable. Also, you cannot specify OPTIONAL for local files.

parameter Specifies Model 204 group parameters. Any number of PARAMETER statements can follow, and each can contain as many parameters in any order as fit on one input line. Valid permanent group parameters are described in the table below. All but PRIVATE, PUBLIC, and SEMIPUB must be followed by a value:
Parameter Meaning
ADDLVL Identifies the ADD field level security access level for the files making up the group. The default is 0.
BLDGFT Indicates whether to build an internal field table for this group. Can be YES (default) or NO.

BLDGFT is ignored for groups that include remote members.

MAXFAIL For scattered groups (PQO), the maximum number of optional members that can be unavailable. If more than MAXFAIL files are unavailable, the group fails to open or operations on the group are aborted.

The value of MAXFAIL must be one of the following:

  • An integer between one and the number of optional group members.
  • An asterisk (*), which is equivalent to the number of optional members in the group. This setting means that the group can function without any of its optional members. This is the default.

For ad hoc scattered groups, MAXFAIL is always set to the default.

PCLASSDF Identifies the default user class with respect to the procedures defined for a permanent group.
PRIVATE Indicates that users are asked for a group password when they open the group. The password entered must be valid to open the group.
PRIVDEF Indicates the default privileges for public and semi-public groups. If not specified, default group privileges are set to X'3FFF' (all privileges).
PROCFILE Defines the group's procedure file. Multiple procedure files can be specified with PROCFILE = *, as explained in Temporary group parameters.

With scattered groups, PROCFILE must refer to a local file, and its value cannot be an asterisk (*).

PUBLIC Indicates that users are not asked for a group password when they open the group and are automatically given default group privileges. If none of the parameters PUBLIC, SEMIPUB, or PRIVATE is specified, PUBLIC is the default.
READLVL Identifies the READ field level security access level for the files making up the group. The default is 0.
SELLVL Identifies the SELECT access level for the fields in the files making up the group. The default is 0.
SEMIPUB Indicates that users are asked for a group password to open the group. If the password is valid, the group is opened with the privileges assigned to that password. If the password is invalid, the group is opened with the default group privileges.
UPDTFILE Defines the group's update file.

If used in PQO, UPDTFILE can refer to either local or remote files. If the update file you are naming is a remote file, you can include its remote file specification (AT location).

UPDTLVL Identifies the UPDATE field level security access level for the files making up the group. The default is 0.

Syntax notes

Commas and equal signs are optional.

Example

CREATE PERM GROUP ACCOUNT FROM ACC1, ACC2, ACC3, ACC4 *** M204.0825: READING GROUP PARAMETERS PARAMETER PROCFILE = ACC1, PRIVDEF = X'3FFF' END *** M204.0830: PERM GROUP CREATED

Usage notes

  • The CREATE PERM GROUP command creates a permanent file group from the files specified in the command. A permanent group is a group established by the system manager and maintained permanently in an external file (the CCAGRP file) until it is explicitly deleted. Before a permanent group can be created, the system manager must create the CCAGRP file in which the group definitions are stored. This is accomplished with the CREATEG command.
  • When it processes CREATE PERM GROUP, Model 204 ends any update unit in progress and begins a non-backoutable update unit.
  • Duplicate identifiers for a local file are detected when Model 204 tries to open the group. A Model 204 messages tells you the name of the file duplicates that result from using file synonyms. You cannot:
    • Specify multiple identifiers for the same file in a CREATE GROUP command: that is, you cannot include two synonyms for the same file.

    • Include a synonym and a remote file specification for the same file.

See also