Transaction set guide
EDI 850 Purchase Order
The 850 is the most common X12 transaction. The retailer (buyer) sends it to the supplier (seller). It says: "Here is what I want, in what quantity, where to ship it, and when I want it."
The 850 envelope hierarchy
- ISA — interchange envelope.
- GS — function group, qualifier
POfor purchase orders. - ST — transaction set, ID
850. - BEG — beginning of purchase order. Required.
- REF loop — references (vendor, customer, contract).
- DTM loop — dates (ship-by, deliver-by, cancel-after).
- N1 loop — names and addresses (ship-to, bill-to).
- PO1 loop — line items (one PO1 per item).
- CTT — line item total count.
- SE / GE / IEA — trailers.
Required segments (X12 baseline)
| Segment | Purpose | Required by X12? | Often required by partners? |
|---|---|---|---|
| BEG | PO type, purpose, PO number, date | Yes | Yes |
| REF | Vendor / contract / department references | No | Often (REF*VR, REF*DP) |
| DTM | Dates (ship-by, deliver-by, cancel) | No | Often (DTM*002, DTM*010) |
| N1 / N3 / N4 | Ship-to address | No (loop) | Almost always (N1*ST) |
| PO1 | Line item | Yes | Yes |
| PID | Item description | No | Often |
| CTT | Total line count | Yes | Yes |
| SE | Transaction trailer | Yes | Yes |
BEG segment — the PO header
BEG*00*SA*PO12345**20250506~
- BEG01 — transaction set purpose code.
00= original,01= cancellation,04= change. - BEG02 — purchase order type.
SA= stand-alone,BC= blanket,RL= release. - BEG03 — purchase order number. The retailer's PO number — case-sensitive, must match exactly when you reference it later.
- BEG05 — PO date in YYYYMMDD.
PO1 segment — line items
PO1*1*5*EA*12.50**VC*ABC123*UP*012345678905~
- PO1-01 — line number.
- PO1-02 — quantity.
- PO1-03 — unit of measure (
EA= each,CA= case,LB= pound). - PO1-04 — unit price.
- PO1-06 / PO1-07 — first product ID qualifier + value (
VC= vendor catalog,BP= buyer's part,UP= UPC). - PO1-08 / PO1-09 — second product ID qualifier + value.
The five most common 850 rejections
- Missing REF*VR (vendor number). Most large retailers require their vendor number on every PO.
- Wrong N1 qualifier. N1*ST = ship-to, N1*BT = bill-to, N1*BY = buyer. Mixing them up rejects.
- UPC mismatch. Retailer expects UP qualifier; you sent VC. Or the UPC checksum is wrong.
- CTT line count off-by-one. CTT must equal the count of PO1 segments, not the SE segment count.
- SE segment count wrong. SE-01 must equal the number of segments from ST to SE inclusive.
How to validate an 850 in EDI-X12
- Open the validator.
- Paste your 850, or click Load sample 850.
- Click Validate. Window 2 shows structural issues.
- Click Explain with AI. Window 3 walks through every segment.
Related
- 856 ASN — the response to your 850
- 810 Invoice — billing back the PO
- 997 — confirming you received the 850
- Glossary of qualifier codes
Got an 850 that's getting rejected?
Paste it into the validator with the rejection text. The AI will walk through what to fix.
Open the validator