Create Query Management Form (CRTQMFORM)

The Create Query Management Form (CRTQMFORM) command allows you to create a query management form from a specified source file member. The query management form defines how a report is to look when data from running a query is displayed or printed.

Parameters

Keyword Description Choices Notes
QMFORM Query management report form Qualified object name Required, Positional 1
Qualifier 1: Query management report form Name
Qualifier 2: Library Name, *CURLIB
SRCFILE Source file Qualified object name Optional, Positional 2
Qualifier 1: Source file Name, QQMFORMSRC
Qualifier 2: Library Name, *LIBL, *CURLIB
SRCMBR Source member Name, *QMFORM Optional, Positional 3
TEXT Text 'description' Character value, *SRCMBRTXT, *BLANK Optional
AUT Authority Name, *USE, *CHANGE, *ALL, *EXCLUDE, *LIBCRTAUT Optional
REPLACE Replace object *YES, *NO Optional

Query management report form (QMFORM)

Specifies the query management form to be created.

This is a required parameter.

This is a required parameter.

Qualifier 1: Query management report form

name
Specify the name of the form to be created.

Qualifier 2: Library

*CURLIB
The current library for the job is used to locate the form. If no library is specified as the current library for the job, the QGPL library is used.
name
Specify the name of the library where the form is located.

Source file (SRCFILE)

Specifies the source file containing the source for the form being created. The form is identified by the name specified on the QMFORM parameter.

Qualifier 1: Source file

QQMFORMSRC
IBM-supplied source file QQMFORMSRC contains the source for the form to be created.
name
Specify the name of the file containing the source for the form to be created.

Qualifier 2: Library

*LIBL
All libraries in the library list for the current thread are searched until the first match is found.
*CURLIB
The current library for the job is searched. If no library is specified as the current library for the job, the QGPL library is used.
name
Specify the name of the library to be searched.

Source member (SRCMBR)

Specifies the source file member containing the form source to be created.

*QMFORM
The member name is the same as the form name specified on the QMFORM parameter.
name
Specify the name of the member that contains the form source.

Text 'description' (TEXT)

Specifies the text that briefly describes the query management form.

*SRCMBRTXT
The descriptive text for the object being created is the same as the text description of the source member. If the source member has no text description, or if it is blank, the comment inside the externalized form is used if one exists; otherwise *BLANK is assumed.
*BLANK
No text is specified. If this command causes an object to be replaced, any existing text for the object is replaced with blank text.
character-value
Specify no more than 50 characters of text, enclosed in apostrophes. The apostrophes are not part of the 50-character string.

Authority (AUT)

Specifies the authority you are giving to users who do not have specific authority for the object, who are not on an authorization list, and whose group profile or supplemental group profiles do not have specific authority for the object.

*LIBCRTAUT
The system determines the authority for the object by using the value specified for the Create authority (CRTAUT) parameter on the Create Library command (CRTLIB) for the library containing the object to be created. If the value specified for the CRTAUT parameter is changed, the new value will not affect any existing objects.
*CHANGE
The user can perform all operations on the object except those limited to the owner or controlled by object existence (*OBJEXIST) and object management (*OBJMGT) authorities. The user can change and perform basic functions on the object. *CHANGE authority provides object operational (*OBJOPR) authority and all data authority. If the object is an authorization list, the user cannot add, change, or remove users.
*ALL
The user can perform all operations except those limited to the owner or controlled by authorization list management (*AUTLMGT) authority. The user can control the object's existence, specify the security for the object, change the object, and perform basic functions on the object. The user also can change ownership of the object.
*USE
The user can perform basic operations on the object, such as running a program or reading a file. The user cannot change the object. Use (*USE) authority provides object operational (*OBJOPR), read (*READ), and execute (*EXECUTE) authorities.
*EXCLUDE
The user cannot access the object.
name
Specify the name of an authorization list to be used for authority to the object. Users included in the authorization list are granted authority to the object as specified in the list. The authorization list must exist when the object is created.

Replace object (REPLACE)

Specifies whether an existing object with the same name and type in the library to receive the output is replaced with the output of this command.

*YES
An existing object is replaced with the output of this command.
*NO
An existing object is not replaced with the output of this command.

Examples

CRTQMFORM   QMFORM(FORMEMP)  SRCFILE(RPTLIB/FORMSRC)

This command creates a form named FORMEMP in the current library. The form source is in member FORMEMP, which is located in source file FORMSRC in library RPTLIB.

Error messages

*ESCAPE Messages

QWM2701
&1 command failed.
QWM2703
&1 command ended.
QWM2705
Source file &1 in &2 not available.
QWM2706
&1 in &2 not replaced.