What is EDI?
EDI, electronic data interchange, is the exchange of business documents between companies' computers in a fixed format. The receiving system reads them without anyone retyping. A former US federal standard, FIPS 161-2, defined it as the computer-to-computer exchange of strictly formatted messages. A purchase order, its acknowledgment, the ship notice, and the invoice each have their own document type.
In North America the format is ANSI X12, which GS1 Canada calls the most used EDI standard in Canada and the United States. X12 is developed by ASC X12, an ANSI-accredited standards body that holds the copyright in the standards and was chartered in 1979. The international standard is UN/EDIFACT, published by the United Nations body UN/CEFACT, and GS1's EANCOM is a subset of it.
What an EDI translator does
An X12 file is plain text written for machines. Segments end with a terminator such as a tilde, elements are split by a separator such as an asterisk, and short codes stand for meanings. A translator turns that text into something a person or an ERP can use. The viewer above reads any X12 file and shows:
- the envelope: who sent it, to whom, when, and its control numbers
- an 850, 855, 856, or 810 as a document, with parties, dates, line items, and totals
- every segment with its name, and each element's meaning when you select the segment
- the envelope checks a receiving translator runs, in plain words
- the line items as a CSV file for Excel
Other transaction sets show their envelope, parties, dates, and every segment. EDI software also writes documents and maps them into the ERP. This page reads a file so that a person can understand it.
How to read an X12 file
Every interchange starts with an ISA segment of fixed length, and it sets the delimiters for the rest of the file. Microsoft's EDI documentation spells out where each one sits:
- The element separator is the fourth character of the ISA segment, right after "ISA".
- ISA16 holds the component separator, used inside composite elements.
- The segment terminator is the character after ISA16, the 106th of the segment.
The sender picks these characters, and X12 says they cannot appear inside the data of that interchange. Three envelopes then nest inside one another. Each trailer repeats a count and a control number from its header, as the 3M 850 specification lists them:
| Header | Trailer | What the trailer repeats |
|---|---|---|
| ISA | IEA | IEA01 counts the functional groups, and IEA02 repeats the interchange control number in ISA13. |
| GS | GE | GE01 counts the transaction sets, and GE02 repeats the group control number in GS06. |
| ST | SE | SE01 counts the segments from ST to SE, both included, and SE02 repeats ST02. |
The viewer checks each pair and says which one is off.
Read the purchase orders that do not come as EDI
ThriveAI's order desk reads the purchase orders customers email and matches each line to your items and prices. It drafts the ERP order for a person to approve. Derik will tell you what a four-week build would cover.
See order desk automationX12 versions 4010 and 5010
X12 published version 004010 on January 1, 1998, and 005010 on January 1, 2004. GS08 carries the version each functional group uses. One envelope change matters to a reader of the file. Before version 4020, ISA11 holds the letter U, and from 4020 on it holds the repetition separator, as Boomi's X12 settings describe. The viewer reads ISA12 to tell which.
Guides published as recently as 2024 still specify 4010, such as 3M's 850 specification.
The documents of one order
X12's supply chain flow runs from the purchase order to the payment, with a 997 sent back after each document received:
| Set | Document | Sent by | What it carries |
|---|---|---|---|
| 850 | Purchase order | Buyer | The order: items, quantities, prices, ship-to, and dates |
| 997 | Functional acknowledgment | Whoever received a document | Whether the document passed the syntax checks |
| 855 | Purchase order acknowledgment | Supplier | Each line accepted, changed, backordered, or rejected |
| 856 | Ship notice (ASN) | Supplier | What shipped, packed how, for which orders |
| 810 | Invoice | Supplier | The bill for what shipped |
| 820 | Payment order and remittance advice | Buyer | The payment and what it covers |
A 997 reports whether a document arrived and passed the syntax checks. X12 says it reports syntax only, not meaning, so a 997 does not tell you the buyer agrees with your prices.
EDI vs ERP
An ERP is the system where a company keeps its orders, inventory, and invoices. EDI is a format for moving documents between two companies' systems. An 850 that arrives by EDI becomes a sales order in the supplier's ERP only after a translator maps its segments to the ERP's fields. Someone then checks what does not match, such as an unknown item or a price that differs from the contract. The guide to the sales order covers that step, and the order to cash process places it in the whole cycle.
How to convert an EDI file to Excel
Open the file in the viewer, choose the transaction set if the file holds more than one, and select Download CSV. The CSV holds one row per line item with its quantity, unit, price, part numbers, and description, and it opens in Excel. For an 856, each row also carries its purchase order number and the label of the pallet or carton it shipped in.
Customers who send PDFs instead of EDI
EDI covers the customers who are set up to send it. The rest send purchase orders by email, as a PDF, a spreadsheet, a scan, or lines typed into the message. Someone then keys each line into the ERP. ThriveAI's order desk reads those orders and matches each line to your items and to that customer's prices. It drafts the ERP order beside the original for a person to approve. Nothing enters the ERP before that approval.
What stays in your browser
The file is read in this browser and never uploaded. The viewer is plain JavaScript with no library to download, so it keeps working offline once the page has loaded. The page counts how often the viewer is used, with the transaction set number and the number of segments and lines. It never records the file or anything in it.