Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

[ Image Removed |../../index.htm#lansa/ugub_30055.htm]
You are here:

...

This screen is displayed when:

  • Reviewing the virtual fields in a file definition for possible change.
  • Defining the virtual fields in a new file definition.


 

 

 DC@P201601     MMMMMMM                     
                                                                       
 File  : XXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX          (XXXX ) 
                                                                       
 Edit virtual field derivation code . . . . . . ___  YES, NO     
                                                                       
                                                       Review/Change  
                                                       Extended       
   Sequence Name     Description                       Definition  PJF 
                     PJF's before virtuals derived on input
    99999  XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   _     B  
                    Virtual Fields derived after input 
    99999  XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX          
                    PJF's after virtuals derived after input
    99999  XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   _     A  
                    Virtual Fields derived before output 
    99999  XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX          
                    Undefined Virtual Fields
    99999  XXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX   _     U  
                                                                       
                                                                       
 Fnn=Help Fnn=Exit Fnn=Add/Create Fnn=Cancel Fnn=Change Fnn=Delete  
 Fnn=Messages                                                          
 

 |
Note: MMMMMMM on line 2 indicates mode as Display, Add, Change or Delete.
Working from the Virtual Fields in File Definition screen you can:

...

The Action Box that will provide these options is as follows:
 

             _______________________________________     
            /  Virtual Field Extended Definitions   \     
            :                                       :     
            :  Use cursor to select an option       :     
            :   Substringing                        :     
            :   Concatenation                       :     
            :   Mathematical calculations           :     
            :   Date conversion                     :     
            :                                       :     
            :  Then use cursor to initiate action   :     
            :   Perform selected request            :     
            :   Return to previous screen           :     
            : F1=Help   Fnn=Cancel   F14=Messages   :     
            _______________________________________/     
 
 

 |
If an option has been selected then the relevant screen will be displayed, these screens are described in more detail later in this section.
Note: The mathematical calculation option will only be available if the selected virtual field is numeric.
In addition, any field nominated as a virtual field must not have been defined as a "real" field in this file definition. Refer to elsewhere for details of how "real" fields are defined in a file definition.
PJF
This display-only column indicates that the field is a Predetermined Join Field retrieved before (B) virtual fields which are derived after input from file, or after (A) virtual fields which are derived after input from file, or is a virtual field which is undefined (U).
Virtual Field Extended Definitions
The Virtual field extended definition function allows you to derive virtual fields from real fields and vice versa by mapping data using the Substringing, Concatenation and Date conversion options. It also allows you to perform mathematical calculations to derive a resulting virtual field.
This function dramatically reduces the requirement and dependence of RPG/400 programming skills for specifying RPG/400 code to derive virtual fields, the four extended definition options available - substringing, concatenation, mathematical calculation and date conversion are the most common cases used to derive virtual fields and should be used wherever possible to derive the resulting virtual field. It is recommended that you only use RPG/400 code to derive virtual fields where the already defined options cannot produce the desired result.
Each one of the virtual field extended definition options is described in more detail in:
3.15.4 Substringing of a Field/Record
3.15.5 Concatenation of Field(s)
3.15.6 Mathematical Calculation of a Field
3.15.7 Date Conversion of a Field.
[ Image Removed |../../index.htm#lansa/ugub_30055.htm]