EDI troubleshooting for 3PLs
Why retailers reject 856 ASNs (and how to read the 997/824)
A rejected ASN rarely tells you the cause in plain words. It tells you where to look. The 997 and the 824 each answer a different question, and a lot of time on rejects goes to reading the wrong one.
The short answer
Retailers reject 856 ASNs for two kinds of reasons: the file is built wrong, which the 997 reports, or the data doesn't match their records, which comes back on an 824 or a portal report.
The first kind is structure. A required segment is missing, a date isn't a real date, a code isn't on the allowed list. The retailer's translator catches it the moment the file arrives, and the 997 points at the segment and element.
The second kind is business rules. The PO number doesn't exist, the ship-to isn't a valid distribution center, the carton count doesn't add up, or an SSCC on the ASN doesn't match the label the dock scanned. The file was fine. The content wasn't. That's the 824's job, although many retailers report it in a supplier portal or a scorecard instead.
So the first question for any reject is: did the 997 accept the file? If it did, the answer isn't in the 997.
997 vs 824 for an ASN
| 997 Functional Acknowledgment | 824 Application Advice | |
|---|---|---|
| Answers | Was the file built correctly? | Does the content pass our business rules? |
| Sent when | Usually soon after the file arrives | After the retailer's system processes the ASN, sometimes after receiving |
| Points to | Segment and element: AK3, AK4 | The original document: OTI, with the reason in TED or NTE |
| Result codes | AK5: A accepted, E accepted with errors, R rejected | OTI01: TA accepted, TE accepted with error, TR rejected |
| Usually fixed in | The map or translator | WMS data, master data, packing or timing |
| Every partner sends it? | Most do, if agreed at setup | No. Some use a portal, an email, or a scorecard |
How to read a 997 for an 856
Here's a trimmed 997 for a rejected ASN, with made-up numbers:
AK1*SH*5120~
AK2*856*0001~
AK3*DTM*7**8~
AK4*2*373*8*20261131~
AK5*R*5~
AK9*R*1*1*0~
AK1*SHsays which group is being acknowledged.SHis the functional group for ship notices, and 5120 is the group control number from yourGS.AK2names the transaction set: an 856, control number 0001 from yourST.AK3is the segment in trouble: theDTMat position 7 in the transaction set. The last code, 8, means "segment has data element errors".AK4narrows it down: element 2 of that segment, data element 373 (a date), error 8, "invalid date". It even copies the bad value back. November has 30 days.AK5*Rmeans this ASN was rejected.AK9sums up the group: one sent, one received, none accepted.
Two things trip people up here. Segment position counts from ST, not from the start of the file. And AK5*E, accepted with errors, is easy to miss because the document went through. Read those anyway. A warning today can become a reject later, if the partner tightens its checks.
If nothing comes back at all, look further out. A wrong receiver ID in the ISA or GS, or a test/production flag set wrong, can mean the retailer never processed the file. Check the VAN or AS2 log, and the TA1 if that partner sends one.
How to read an 824 for an 856
The 824 points back at the ASN by its own reference, and puts the reason in a code plus free text. Another made-up example:
BGN*00*AA-30917*20261027~
OTI*TR*SI*SH93058*****5120*0001*856~
TED*011*SSCC 001234560000044180 SCANNED, NOT ON ASN~
OTI01=TR: the ASN was rejected.TEwould mean accepted with an error, andTAaccepted.OTI02andOTI03identify which ASN: here the shipment ID from yourBSN02, SH93058. The qualifier varies by partner.OTI08toOTI10repeat the group and transaction control numbers and the document type, so you can match it to the 997.TED01is a broad category (011 is "not matching").TED02is the free text, and that's where the real answer usually is.
The codes are standard. The free text isn't. Every retailer writes it differently, some put a reference to their own error list at the front, and some add NTE lines underneath. Keep the retailer's 824 error list next to their 856 guide. It's often published in the same place.
In this example the 997 would have been clean. The file was valid. The dock scanned a carton label, 001234560000044180, that the ASN never listed, probably because the ASN still carried 001234560000044173 for that box. Nothing in the map is wrong. The question is when the label was printed versus when the ASN was built.
Common reject causes and where they get fixed
These are the causes that come up again and again for 856s at a 3PL. The middle column is what to look for first.
| Reject cause | What you'll usually see | Usually fixed in |
|---|---|---|
Missing or empty required segment (for example no TD1 or PRF) | 997: AK3 code 3, mandatory segment missing, or AK4 code 1, mandatory element missing | The map, or the WMS field that feeds it |
| Bad date, time or code value | 997: AK4 code 7 (invalid code), 8 (invalid date) or 9 (invalid time), with the bad value copied back | The map: date format, qualifier list |
| Wrong IDs or test/production flag in the envelope | Often nothing at all, or a TA1 reject | Partner setup in the translator |
PO number not found (PRF01) | 824 or portal: PO not found or closed | Order data from the brand's 940, or the map |
Ship-to or DC number not valid (N1*ST) | 824 or portal: invalid location | Master data, or the 940-to-856 mapping of the ship-to |
SSCC on the ASN doesn't match the carton label (MAN) | 824 or receiving report, often after the truck arrives | Packing and label printing, and when the ASN is built |
Quantities don't add up (SN1 vs carton count in TD1 vs number of pack levels) | 824: quantity or count mismatch | WMS pack data, or how the map rolls up the hierarchy |
Hierarchy not what the guide asks for (no pack level, tare level missing, wrong parent in HL) | 824 or a compliance report. Some partners catch it in the 997 if they validate against their own guide | The map, after agreeing the hierarchy at setup |
| Same shipment ID sent twice | 824: duplicate (TED01 006 is the standard code) | Resend procedure. Check whether the guide wants a new BSN02 or accepts a replace (BSN01 = 05) |
| ASN sent late, after the truck or outside the guide's window | Often no reject. It shows up later on a scorecard or as a chargeback | Schedules: WMS close, 945 timing, the ASN job |
The last row often gets no reject at all, which is why it's easy to miss until the chargeback. We covered where late ASNs come from in 945 vs 856.
The hierarchy row is worth settling before go-live, not after the first reject. Which levels, which order, and whether mixed cartons are allowed should be in the partner sheet. That's part of our trading partner onboarding work.
What to do with the next reject
- Find the 997 for that ASN first. Match it by group and transaction control number. If
AK5is R, the answer is inAK3andAK4. Go to the map. - If the 997 accepted it, find the 824 or the portal message. Match
OTI03to yourBSN02. ReadTED02and anyNTElines, not just the code. - Pull the ASN as sent, not as the WMS shows it today. Data can change after the file goes out, and you need to see what the retailer saw.
- Decide where it broke: map, WMS data, master data, packing, or timing. The table above is a starting point.
- Fix it there, then check the guide before you resend. Some want a corrected ASN with a new shipment ID, some accept a replacement, and the rules can differ once the freight has been received.
- Write it down by cause. Ten rejects with one cause are one fix. Without a list, they look like ten problems.
If the same rejects keep coming back, that's what our EDI error fixes work is for: trace it to the cause, fix it at the source, and resend what's stuck.
When 824s pile up, sorting them is mostly reading. The codes can be grouped by plain rules. The free text in TED02 and NTE is where AI can help, by putting reworded versions of the same problem in one group. A person still decides every fix and every resend. We describe how we set that up on the AI for EDI operations page.
FAQ
Does an accepted 997 mean the retailer accepted the ASN?
No. An accepted 997 only means the file was built correctly. The retailer can still reject the content later, on an 824, in a supplier portal or on a scorecard, for example when an SSCC or a PO number doesn't match.
What does AK5*E mean on a 997?
Accepted with errors. The ASN went through, but the partner's translator noted problems, listed in the AK3 and AK4 segments above it. Fix them anyway, because a partner can turn those warnings into rejects later.
Why didn't we get an 824 when the retailer says the ASN was wrong?
Not every retailer sends 824s for ASNs. Many report ASN problems in a supplier portal, by email or on a scorecard, sometimes weeks later. Ask at setup how each partner reports ASN errors and who receives them.
Can a 3PL resend a rejected 856?
Usually, but check the retailer's guide first. Some want a corrected ASN with a new shipment ID, some accept a replacement, and the rules can differ once the freight has been received.
ASNs coming back rejected?
Send us one rejected 856 with the 997 and 824 that came back. We'll read them with you and show you where it broke. The first 30-minute review is free.
Book a free 30-minute EDI reviewOr call (917) 300-1831