You are here: Job and Form Set Rules Reference > JDT Rules Reference > Ext2GVM

Ext2GVM

Use this form set level rule to add data from the extract list into previously defined global variables. To use the rule, you must add it to the AFGJOB.JDT file after the extract data is loaded.

You can also use this rule to get data into the NEWTRN.DAT file during GenData processing instead of using Trn_Fields. To do this you define a field for the data to be mapped in the TRNDFDFL.DFD file and then use the Ext2GVM rule to map the data from extract file to the NEWTRN.DAT file.

Syntax

;Ext2GVM;;(parameters);

You can use these parameters with this rule:

Parameter

Description

SearchMask

One or more pairs of offsets and data (search criteria) in a comma-delimited list.

DataLocation

The offset and length of the data in the extract record.

GVMName

The name of the GVM variable where the data will be stored.

SuppressFlag

Enter S to suppress error messages if the search mask is not found in a transaction. The default is blank, which tells the system not to suppress error messages.

Example

The following example locates the extract record that matches the search mask (1, D1) and moves the value found at position 21 for a length of 5 to the global variable TestVar. In addition, it suppresses the error messages if the search mask is not found in the transaction.

<Base Rules>

... ...

... ...

;CreateGlbVar;;TestVar,CHAR_ARRAY,5;

... ...

<Base Form Set Rules>

... ...

;Ext2GVM;;1,D1 21,5,TestVar,S;

... ...

Note Refer to the DAL Reference for information on these related DAL functions: GVM, HaveGVM, and SetGVM.