TEMPORARY vs PERMANENT field attributes in MODIFY MAP statements

Document ID : KB000021772
Last Modified Date : 14/02/2018
Show Technical Document Details


The following document is an explanation of how the TEMPORARY/PERMANENT options impact a MODIFY MAP command.


When an application program is processing map field attributes, the CA-IDMS mapping facility internally maintains one set of PERMANENT attributes and one set of TEMPORARY attributes for each map and field attribute that can be modified.

At the beginning of program execution, each PERMANENT and TEMPORARY attribute value is initialized with the value from the map definition.

When a MODIFY MAP ... PERMANENT/TEMPORARY command is encountered, the appropriate attribute is modified.

When a #MAPOUT (DISPLAY) is executed, the value in the TEMPORARY attribute is used to determine the particular attribute value, and then the TEMPORARY attribute value is reset to the PERMANENT value.

In this way, the TEMPORARY option on a MODIFY MAP command will set the value for the next #MAPOUT only. The PERMANENT option on a MODIFY MAP command will set the default value for ALL subsequent #MAPOUTs in the current program execution.

Therefore, it also follows that a MODIFY MAP ... PERMANENT command that is issued chronologically after a MODIFY MAP ... TEMPORARY command for the same field attributes will have no effect on the immediate next #MAPOUT.

Note: If both temporary and permanent modifications are specified, the temporary changes override the permanent changes for the first mapout operation only.

Additional Information:

For more information, see the Mapping Facility manual, "Runtime Considerations", "Map Inquiry and Modification", "Temporary VS Permanent Modifications".