ediDataElement

The ediDataElement object can represent either a composite element or a simple data element. A simple data element is the smallest structure in the standard, which not only carries the actual business data, but also contains properties that describe the data.  A composite element contains a collection of simple data elements.  A data element has these following properties:

Data Types in X12 standard

For ASC/X12 the following data types are available:

Data Types in EDIFACT standard

For UN/EDIFACT the following data types are available:

Data Length

The length of the data element basically counts the number of graphic character in the data. For decimal and numeric data types, the following apply:

  1. The “+” sign that indicates that the number is positive should be suppressed from the data stream, but if it does occur, it is not included in the data length count.
  2. The “-“ sign that indicates that the number is negative is not included in the data length count.
  3. The decimal point is not included in the data length count.
  4. The trailing exponent indicator “E” is not included in the data length count. Example, 1E3.

Plus and Minus Signs

For decimal and numeric data types the minus/hyphen (“-“) sign preceding a number signifies a negative value while the plus (“+”) sign signifies a positive value. When no sign precedes the number, it is taken as a positive value. When transmitting any number that is positive, the “+” should always be suppressed.

Leading and Trailing Zeros

For decimal and numeric data types, leading zeros should be suppressed unless required to satisfy a minimum length requirement. For EDIFACT, when a decimal point precedes the first digit in the number, a single leading zero is required (example, 0.123). For X12, this leading zero is suppressed (example .123).

When only zeros follow a decimal point, the trailing zeros should be suppressed. However, if it becomes necessary to include the decimal point a single zero should follow the decimal point (example 123.0). Zeros after the decimal to indicate precision is also allowed.

For time data type in X12, the trailing zeros can also be used in decimal seconds to satisfy the minimum length requirement.

Triad Separators

For decimal and numeric data types, triad separators are not allowed. Example. 5,000,000 is not allowed and should be replaced with 5000000.

Spaces

For string, identifier, alphabetic and alphanumeric data types, trailing spaces are suppressed.

Methods

Properties