If you have received 997 stating your transaction was rejected, you might want to look into the 997 to find out what is wrong with the transaction.
Open the 997 in any text editor. The 997 should look something like below.
ISA*00* *00* *08*TESTTESTTEST*12*TESTTESTTEST*210218*1849*U*00403*000002899*0*P*>~
Step 3: Understanding the 997
The AK1 segment(line 4)
Note: Orderful will automatically link the correct 997 to the correct transaction.
This segment indicates which transaction this 997 corresponds to.
AK1-01: Indicates the transaction type being rejected. E.g. IN = Invoice.
AK1-02: Indicates the transaction control number of the transaction being rejected. E.g., 166.
The AK3 segment(line 6)
This segment indicates which line and segment of the EDI transaction have the issue.
AK3-01: Indicates the segment that has the issue. E.g., IT1.
AK3-02: Indicates the segment position in the transaction set, i.e line number of the segment (excluding ISA and GS).
The AK4 segment(line7)
This segment indicates the element position and error code for the segment indicated in AK3.
AK4-01: Indicates the element position in the segment that has the error. E.g., 4. i.e., IT1-04 has the error.
AK4-03: Indicates the error code identifying the type of error in the element indicated by AK4-01.
e.g., 6 indicates an invalid character in the data element. The full list can be found at the bottom of the article.
AK4-04: Indicates the value that was sent in the bad element. E.g., NaN.
Based on the above 997, it can be concluded that the invoice (AK101=IN) had an issue with the IT1 segment (AK3-01 = IT1) at position 4 (AK4-01 = 4) and that IT104 contained the value of NaN.
List of codes for AK4-03:
1: Mandatory data element missing
2: Conditional required data element missing.
3: Too many data elements. More data elements existed than defined for the segment.
4: Data element too short.
5: Data element too long.
6: Invalid character in the data element.
7: Invalid code value.
8: Invalid Date.
9: Invalid Time.
10: Exclusion Condition Violated
12: Too Many Repetitions. More repetitions existed than defined for the segment.
13: Too Many Component. More components existed than defined for the element.
16: Composite Data Structure Contains Excess Trailing Delimiters.