CTX Context

Describes an event context in terms of the application or implementation contexts in force at the time the event occurred and the position in the EDI stream at which that context was activated

Position
Element
Name
Type
Requirement
Min
Max
Repeat
CTX-01
Context Identification
Composite (composite)
Mandatory
10
01
Context Name
String (AN)
Mandatory
1
35
-
Holds the name or 'tag' of a context
02
Context Reference
String (AN)
Optional
1
35
-
Holds a reference to or for a context
CTX-02
Segment ID Code
Identifier (ID)
Optional
2
3
1
Code specifying the segment ID of the data segment in error (See Appendix A - Number 77)
CTX-03
Segment Position in Transaction Set
Numeric (N0)
Optional
1
10
1
The numerical count position of this data segment from the start of the transaction set: the transaction set header is count position 1
CTX-04
Loop Identifier Code
String (AN)
Optional
1
4
1
The loop ID number given on the transaction set diagram is the value for this data element in segments LS and LE
CTX-05
Position in Segment
Composite (composite)
Optional
1
01
Element Position in Segment
Numeric (N0)
Mandatory
1
2
-
This is used to indicate the relative position of a simple data element, or the relative position of a composite data structure with the relative position of the component within the composite data structure, in error; in the data segment the count starts with 1 for the simple data element or composite data structure immediately following the segment ID
02
Component Data Element Position in Composite
Numeric (N0)
Optional
1
2
-
To identify the component data element position within the composite that is in error
03
Repeating Data Element Position
Numeric (N0)
Optional
1
4
-
To identify the specific repetition of a data element that is in error
CTX-06
Reference in Segment
Composite (composite)
Optional
1
01
Data Element Reference Code
String (AN)
Mandatory
1
4
-
Code identifying the location of the data element in the Data Element Dictionary
This element holds the reference number of the simple or composite element at segment level.
02
Data Element Reference Code
String (AN)
Optional
1
4
-
Code identifying the location of the data element in the Data Element Dictionary
This element holds the reference number of the simple element within a composite.

Stedi is a registered trademark of Stedi, Inc. Stedi's EDI Reference is provided for marketing purposes and is free of charge. All names, logos, and brands of third parties listed on our site are trademarks of their respective owners (including “X12”, which is a trademark of X12 Incorporated). Stedi, Inc. and its products and services are not endorsed by, sponsored by, or affiliated with these third parties. Our use of these names, logos, and brands is for identification purposes only, and does not imply any such endorsement, sponsorship, or affiliation.