In some cases, a developer might come across the situation where they would like to know the name of the fields & number of the table, here is how it can be done- Sage ERP X3 has a special feature of getting field’s name of the table with the help of “adxfname” keyword which will […]
In some cases, a developer might come across the situation where they would like to know the name of the fields & number of the table, here is how it can be done-
Sage ERP X3 has a special feature of getting field’s name of the table with the help of “adxfname” keyword which will return you the value & field codes.
Adxfname is a variable table of the [G] class associated with an open table by a File command. The adxfname dimension is given by the [G]nbzon variable (number of fields defined in the table). adxfname contains the field name of the corresponding table. This variable is only accessible in read mode.
Syntax:
[G: abv] adxfname (dim)
[G] – class associated with a table declared by a File command.
abv: Abbreviation of the table.
dim: Index number of the table.
Example-
Refer to the below snippet of code for a better understanding-
Fig 1: Considering purchase order table (PORDER).
Fig 2: In this example, there are 117 fields in the purchase order table.
Fig 3: The fields are started with field names.
Fig 4: Shows the total size of the record.
By using these 4gl index keys a user can find the number of fields & size of the data in a table.
—
For more information on Sage X3 Integration and Services, please contact us at info@akaasa.edev99.in
We will be glad to assist you.
Copyright GerminIT © 2024. All Rights Reserved.