Edit Virtual Field Examples
These examples apply to specifying virtual fields in a file definition. They do not demonstrate how the associated RPG derivation code would be specified.
Refer to the Examples of Virtual Fields & Derivation Code
for more comprehensive examples of the virtual field facility.
- Define three virtual fields called COMPNO, DIVNUM and COSTCT:
|
- Define two virtual fields called YYMMDD and MONTH:
|