997 Structure and Data Sources
This chart shows the structure of a 997 generated by Response Generator. The Source column shows the source of the values in the 997. Many come from the originating transaction:
This table describes the 997 created by Response Generator
|
Loop ID |
I tem |
Name |
Max Use |
Base Req |
Elem Type |
Elem Length Min-Max |
Source of Value |
Notes |
||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
ISA |
Interchange Control Header |
1 |
O |
|
|
|
|||||||
|
|
ISA01 |
Authorization Information Qualifier |
1 |
M |
ID |
2-2 |
00 no authorization information present |
|
||||||
|
|
ISA02 |
Authorization Information |
1 |
M |
AN |
10-10 |
Blank (ten spaces) |
|
||||||
|
|
ISA03 |
Security Information Qualifier |
1 |
M |
ID |
2-2 |
00 no authorization information present |
|
||||||
|
|
ISA04 |
Security Information |
1 |
M |
AN |
10-10 |
Blank (ten spaces) |
Command Line: |
||||||
|
|
ISA05 |
Interchange ID Qualifier |
1 |
M |
ID |
2-2 |
From initiating transaction’s ISA07 |
Command Line: |
||||||
|
|
ISA06 |
Interchange Sender ID |
1 |
M |
AN |
15-15 |
From initiating transaction’s ISA08 |
Command Line: |
||||||
|
|
ISA07 |
Interchange ID Qualifier |
1 |
M |
ID |
2-2 |
From initiating transaction’s ISA05 |
Command Line: |
||||||
|
|
ISA08 |
Interchange Receiver ID |
1 |
M |
AN |
15-15 |
From initiating transaction’s ISA06 |
|
||||||
|
|
ISA09 |
Interchange Date |
1 |
M |
DT |
6-6 |
Current date in YYMMDD format |
|
||||||
|
|
ISA10 |
Interchange Time |
1 |
M |
TM |
4-4 |
Current time in HHMM format |
|
||||||
|
|
ISA11 |
Interchange Control Standards Identifier |
1 |
M |
ID |
1-1 |
U US EDI Community of ASC X12, TDCC, and UCS |
|
||||||
|
|
ISA12 |
Interchange Control Version Number |
1 |
M |
ID |
5-5 |
00401 |
Command Line: |
||||||
|
|
ISA13 |
Interchange Control Number |
1 |
M |
N0 |
9-9 |
Specified interchange control number, zero-filled, starting at “000000001”, and increments by 1 for each Control Number |
|
||||||
|
|
ISA14 |
Acknowledgment Requested |
1 |
M |
ID |
1-1 |
0 No acknowledgment requested |
Command Line: |
||||||
|
|
ISA15 |
Usage Indicator |
1 |
M |
ID |
1-1 |
P production Data |
|
||||||
|
|
ISA16 |
Component Element Separator |
1 |
M |
AN |
1-1 |
Sub-element separator character in effect (Default ‘:’) |
|
||||||
|
|
TA1 |
Interchange Acknowledgment |
1 |
O |
|
|
|
Command Line: -gTA1 |
||||||
|
|
TA101 |
Interchange Control Number |
1 |
M |
N0 |
9-9 |
From initiating transaction’s ISA13 |
|
||||||
|
|
TA102 |
Interchange Date |
1 |
M |
DT |
6-6 |
Current date in YYMMDD format |
|
||||||
|
|
TA103 |
Interchange Time |
1 |
M |
TM |
4-4 |
Current time in HHMM format |
|
||||||
|
|
TA104 |
Interchange Acknowledgment Code |
1 |
M |
ID |
1-1 |
A or R |
|
||||||
|
|
TA105 |
Interchange Note Code |
1 |
M |
ID |
3-3 |
Codes Generated by Response Generator based on encountered Errors |
|
||||||
|
|
GS |
Functional Group Header |
1 |
O |
|
|
|
|
||||||
|
|
GS01 |
Functional Identifier Code |
1 |
M |
ID |
2-2 |
FA functional acknowledgment |
|
||||||
|
|
GS02 |
Application Sender's Code |
1 |
M |
AN |
2-15 |
From initiating transaction’s GS03 |
Command Line: |
||||||
|
|
GS03 |
Application Receiver's Code |
1 |
M |
AN |
2-15 |
From initiating transaction’s GS02 |
Command Line: |
||||||
|
|
GS04 |
Date |
1 |
M |
DT |
8-8 |
Current date in YYYYMMDD format |
|
||||||
|
|
GS05 |
Time |
1 |
M |
TM |
4-8 |
Current time in HHMMSS format |
|
||||||
|
|
GS06 |
Group Control Number |
1 |
M |
N0 |
1-9 |
Specified Group Control Number |
|
||||||
|
|
GS07 |
Responsible Agency Code |
1 |
M |
ID |
1-2 |
X Accredited Standards Committee X12 |
|
||||||
|
|
GS08 |
Version / Release / Industry Identifier Code |
1 |
M |
AN |
1-12 |
Command Line: -dav |
|||||||
|
|
|
|
|
|
|
|
|
|
||||||
|
|
ST |
Transaction Set Header |
1 |
M |
|
|
|
|
||||||
|
|
ST01 |
Transaction Set Identifier Code |
1 |
M |
ID |
3-3 |
997 |
|
||||||
|
|
ST02 |
Transaction Set Control Number |
1 |
M |
AN |
4-9 |
Specified transaction control number, zero-filled, starting at “0001”, and increments by 1 for each transaction control number |
|
||||||
|
|
AK1 |
Functional Group Response Header |
1 |
M |
|
|
|
|
||||||
|
|
AK101 |
Functional Identifier Code |
1 |
M |
ID |
2-2 |
From initiating transaction’s ST01 |
|
||||||
|
|
AK102 |
Group Control Number |
1 |
M |
N0 |
1-9 |
From initiating transaction’s ST02 |
|
||||||
|
AK2 |
AK2 |
Transaction Set Response Header |
1 |
O |
|
|
|
|
||||||
|
AK2 |
AK201 |
Transaction Set Identifier Code |
1 |
M |
ID |
3-3 |
From initiating transaction’s ST01 |
|
||||||
|
AK2 |
AK202 |
Transaction Set Control Number |
1 |
M |
AN |
4-9 |
From initiating transaction’s ST02 |
|
||||||
|
AK3 |
AK3 |
Data Segment Note |
1 |
O |
|
|
|
|
||||||
|
AK3 |
AK301 |
Segment ID Code |
1 |
M |
ID |
2-3 |
Mapped from DTL record; reporting “Segment ID” of where error is reported |
|
||||||
|
AK3 |
AK302 |
Segment Position in Transaction Set |
1 |
M |
N0 |
1-6 |
Segment count offset from last ST to error segment |
|
||||||
|
AK3 |
AK303 |
Loop Identifier Code |
1 |
O |
AN |
1-6 |
Mapped from DTL record; reporting “Loop” of where error is reported |
|
||||||
|
AK3 |
AK304 |
Segment Syntax Error Code |
1 |
O |
ID |
1-3 |
Mapped from DTL record; reporting “Syntax Error Code” of where error is reported |
Error Profile (*.apf) configurable |
||||||
|
AK3 |
AK4 |
Data Element Note |
99 |
O |
|
|
|
|
||||||
|
AK3 |
AK401.1 |
Element Position in Segment |
1 |
M |
N0 |
1-2 |
Mapped from DTL record; reporting “Element Position” of where error is reported |
|
||||||
|
AK3 |
AK402.1 |
Component Data Element Position in Composite |
1 |
O |
N0 |
1-2 |
Mapped from DTL record; reporting “Sub-Element Position” of where error is reported |
|
||||||
|
AK3 |
AK402 |
Data Element Reference Number |
1 |
O |
N0 |
1-4 |
Mapped from DTL record; reporting “Element ID” of where error is reported |
|
||||||
|
AK3 |
AK403 |
Data Element Syntax Error Code |
1 |
M |
ID |
1-3 |
Mapped from DTL record; reporting “Data Element Syntax Error Code” of where error is reported |
Error Profile (*.apf) configurable |
||||||
|
AK3 |
AK404 |
Copy of Bad Data Element |
1 |
O |
AN |
1-99 |
Mapped from DTL record; reporting “Element Data” of where error is reported |
|
||||||
|
AK2 |
AK5 |
Transaction Set Response Trailer |
1 |
M |
|
|
|
|
||||||
|
AK2 |
AK501 |
Transaction Set Acknowledgment Code |
1 |
M |
ID |
1-1 |
A, E, P or R based on configuration options |
Command Line: -pt -LenientAK501 |
||||||
|
AK2 |
AK502 |
Transaction Set Syntax Error Code |
1 |
O |
ID |
1-3 |
Set to 1 if an 11003 (Set Not Supported) error is encountered, otherwise empty |
|
||||||
|
AK2 |
AK503 |
Transaction Set Syntax Error Code |
1 |
O |
ID |
1-3 |
Set to 1 if an 11208 (Set Trailer Not Found) error is encountered, otherwise empty |
|
||||||
|
AK2 |
AK504 |
Transaction Set Syntax Error Code |
1 |
O |
ID |
1-3 |
Set to 1 if a 10913 (Set Control Number Mismatch) error is encountered, otherwise empty |
|
||||||
|
AK2 |
AK505 |
Transaction Set Syntax Error Code |
1 |
O |
ID |
1-3 |
Set to 1 if a 10917 (Bad Segment Count) error is encountered, otherwise empty |
|
||||||
|
AK2 |
AK506 |
Transaction Set Syntax Error Code |
1 |
O |
ID |
1-3 |
Set to 5 if any error occurs in the set |
|
||||||
|
|
AK9 |
Functional Group Response Trailer |
1 |
M |
|
|
|
|
||||||
|
|
AK901 |
Functional Group Acknowledge Code |
1 |
M |
ID |
1-1 |
A, P or R based on configuration options |
Command Line: |
||||||
|
|
AK902 |
Number of Transaction Sets Included |
1 |
M |
N0 |
1-6 |
Number of Transaction Sets Included |
|
||||||
|
|
AK903 |
Number of Received Transaction Sets |
1 |
M |
N0 |
1-6 |
Number of Received Transaction Sets |
|
||||||
|
|
AK904 |
Number of Accepted Transaction Sets |
1 |
M |
N0 |
1-6 |
Number of Accepted Transaction Sets |
|
||||||
|
|
AK905 |
Functional Group Syntax Error Code |
1 |
O |
ID |
1-3 |
Generated by Response Generator based on specific error codes encountered at the Group level. Possible values are 2, 3, 4, 5, 14, 19, 21, 24. |
|
||||||
|
|
AK906 |
Functional Group Syntax Error Code |
1 |
O |
ID |
1-3 |
Not used |
|
||||||
|
|
AK907 |
Functional Group Syntax Error Code |
1 |
O |
ID |
1-3 |
Not used |
|
||||||
|
|
AK908 |
Functional Group Syntax Error Code |
1 |
O |
ID |
1-3 |
Not used |
|
||||||
|
|
AK909 |
Functional Group Syntax Error Code |
1 |
O |
ID |
1-3 |
Not used |
|
||||||
|
|
|
|
|
|
|
|
|
|
||||||
|
|
SE |
Transaction Set Trailer |
1 |
M |
|
|
|
|
||||||
|
|
SE01 |
Number of Included Segments |
1 |
M |
N0 |
1-10 |
Count of Segments in output transaction |
|
||||||
|
|
SE02 |
Transaction Set Control Number |
1 |
M |
AN |
4-9 |
Matches ST02 of output transaction |
|
||||||
|
|
GE |
Functional Group Trailer |
1 |
O |
|
|
|
|
||||||
|
|
GE01 |
Number of Transaction Sets Included |
1 |
M |
N0 |
1-6 |
Count of ST/SEs in output transaction |
|
||||||
|
|
GE02 |
Group Control Number |
1 |
M |
N0 |
1-9 |
Matches GS06 of output transaction |
|
||||||
|
|
IEA |
Interchange Control Trailer |
1 |
O |
|
|
|
|
||||||
|
|
IEA01 |
Number of Included Functional Groups |
1 |
M |
N0 |
1-5 |
Count of GS/GEs in output transaction |
|
||||||
|
|
IEA02 |
Interchange Control Number |
1 |
M |
N0 |
9-9 |
Matches ISA13 of output transaction |
|
||||||