MRM TDS format: Determining the length of simple data values

The TDS format supports two categories of simple data types: textual and non-textual.

The Physical Type of an element determines whether it is categorized as textual or non-textual.

Textual data
Physical Type is either Text or TLOG Specific. For textual data, the Data Element Separation of the parent complex type or group determines how the length of the data is determined. See MRM TDS format: Data element separation and its subtopics.
Non-textual data
Elements of all other Physical Types are non-textual. The length of non-textual data is determined by the Physical Type of the element. For non-textual data, the Data Element Separation property of the parent complex type or group does not determine the length, unless Data Element Separation is Use Data Pattern. See MRM TDS format: Data pattern separation types for more information.

The following table describes how the length of data is determined for each Physical Type.

Physical Type Determination of Length
Text
TLOG Specific
The Data Element Separation of the parent complex type or group determines how the length of the data is determined.
External Decimal
Integer
Packed Decimal
Float
Time Seconds
Time Milliseconds
Uses the value of the Length property of the element.

If Physical Type is Time Seconds, the Length property is set to 4. If Physical Type is Time Milliseconds, the Length property is set to 8. In neither case can this value be changed.

Length Encoded String 1
Length Encoded String 2
Uses the encoded length value in the data.
Null Terminated String
Uses the null terminator at the end of the data.
Binary
Uses the value of the Length Reference or Length property of the element.