DataItem part in EGL source format

You declare a DataItem part in an EGL file, which is described in EGL source format.

An example of a data item part is as follows:

  DataItem myDataItemPart
    BIN(9,2)
  end

The syntax diagram for a dataItem part is as follows:


Syntax diagram for a dataItem part

DataItem dataItemPartName ... end

Identifies the part as a dataItem part and specifies the name. For rules, see naming conventions.

primitiveType

The primitive type assigned to the dataItem part.

length

An integer that reflects the length of the dataItem part. The value of any variable that is based on the part includes the specified number of characters or digits.

decimals

For a numeric, fixed type other than MONEY (specifically, BIN, DECIMAL, NUM, NUMC, or PACF), you may specify decimals, which is an integer that represents the number of places after the decimal point. The maximum number of decimal positions is the smaller of two numbers: 18 or the number of digits declared as length. The decimal point is not stored with the data.

"dateTimeMask"

For items of type INTERVAL or TIMESTAMP, you may specify "dateTimeMask", which assigns a meaning (such as "year digit") to a given position in the item value. The mask is not stored with the data.

property

An item property, as described in Overview of EGL properties and overrides.

Related concepts
DataItem part
EGL projects, packages, and files
Overview of EGL properties and overrides
References to parts
Parts

Related tasks
Syntax diagram

Related reference
EGL source format
Function part in EGL source format
Indexed record part in EGL source format
MQ record part in EGL source format
Naming conventions
Primitive types
Program part in EGL source format
Relative record part in EGL source format
Serial record part in EGL source format
SQL record part in EGL source format