EDI Mapping

Since both EDI and XML can carry similar information, it's a shame that the same tools haven't historically been able to operate on both seamlessly. Until now. Stylus Studio® Adapters let you transparently convert EDI to XML and back.

Why is this interesting? Because there are excellent tools for transforming XML and these can now be applied to mapping EDI to other formats, and mapping between variants of EDI.

Translating EDI to XML

EDI is a generic term for a family of formats describing commercial data.

Stylus Studio® includes tools for converting raw EDI files in either the EDIFACT or X12 formats directly from their raw state into fully-documented XML.

Using the EDI to XML adapters, any tool that works against XML can now work against EDI — XSLT, XQuery, and so forth. You can even validate EDI against custom XML Schemas!

Translating XML to EDI

Stylus Studio® also handles converting XML into well-formed EDI.

To aid in this, you may build XML Schemas from the EDI dictionaries, so that you may map against them, or even validate your XML against the EDI specifications.

EDIFACT Versions Supported

All syntax versions 1 through 4 are recognized and supported transparently.

Stylus Studio® will automatically discover and convert any EDIFACT document of any message type from any published version, which covers D93A through D05A (plus the early editions 88-1, 90-2, 91-1, 92-1, 93-2, and S93A).

To see a complete list of all message types that are defined across all versions go to the EDIFACT Standards Grid.

Each standard is also meticulously documented at the EDIFACT Zone.

X12 Versions Supported

All versions of X12 that DISA (the X12 organizing body) has made available electronically are fully supported by Stylus Studio®. Every transaction set across every release, from 3030 through 5020, is supported.

X12 documents contain embedded descriptive information which Stylus Studio® uses to determine the coding and release automatically, so you do not have to manually set those options before reading X12 EDI files.

To see which transaction sets are available by release, go to the X12 Standards Grid.

Validating EDI Content with XML Schemas

Stylus Studio® lets you create XML Schema files that correspond to the converted raw EDI documents.

Mapping EDI Content with XML Schemas

Imagine being able to use the same mapper for mapping EDI documents that you use for mapping XML documents. With the bidirectional EDI to XML adapters, you can.

Either a representative EDI document, or an XML Schema generated from the specifications for a particular X12 transaction set or EDIFACT message may be used as either the source or target (or both) of a transformation map that will generate either XSLT or XQuery, at your option.

EDI Tutorial (or "What's the difference between EDIFACT and X12 anyway?")

EDI - "Electronic Data Interchange"

EDI is a family of standards, including EDIFACT, HL7, X12, IATA, ODETTE, TRADACOMS and a plethora of others. They are all text file formats, which are structured so that each row of text begins with a marker that tells what kind of record that row contains, and each data item is separated by some unique character.

If you want to know which vocabulary a specific message type belongs to, generally the name or version number will give it away:

three digitsX12 transaction set104, 810, 837, 850
four digitsX12 release3030, 4041, 5020
six digitsX12 release003030, 004041, 005020
two digits then an 'A', 'B' or 'C'EDIFACT version93A, 99B, 04A
'D' or 'S'; two digits; and 'A', 'B' or 'C'EDIFACT versionD93A, D01C, D05A
dot releasesHL7 version2.3, 2.3.1, 2.5
file begins "UNA" or UNB"EDIFACT documentUNA:+.? '
file begins "ISA"X12 documentISA:00: lots more :U:00304:000032123:0:P:*~
file begins "MSH"HL7 documentMSH|^~\&|||||||ADT|


This is a United-Nations sanctioned file format. It encompases many different message types, relating to all sorts of business transactions and there are many different versions of the messages. Stylus Studio® loves to parse EDIFACT files. It fully supports all message types in all versions from D93A to D05A, using a native adapter that is just a comfortable going from EDIFACT to XML as to the reverse.

The XML that Stylus Studio® generates will take an EDIFACT file and turn it into fully-commented XML (a unique feature!). It can also generate XML Schemas for the XML equivalent of any EDIFACT message type supported, which can be used both for mapping and for validation.

The cryptic EDIFACT segment LIN+1+1+0764569104:IB' turns into the following well-documented XML:
LIN01><!--1082: LINE ITEM IDENTIFIER-->1</LIN01>
LIN0301><!--7140: Item identifier-->0764569104</LIN0301>
LIN0302><!--7143: Item type identification code-->IB<!--ISBN (International Standard Book Number)--></LIN0302>

The Stylus Studio® team has provided an extensive description of all EDIFACT messages, segments, elements and code lists at the EDIFACT Zone. For a concise summary of which message types the EDIFACT standard supplies for each version, see X12 Standards Grid


This is another EDI standard, governed by a group named ASC and whose secretariat is a group named DISA, of which DataDirect Technologies is a member.

Stylus Studio® of course supports all currently electronically published versions of this standard, across all transaction sets, from release 3030 to 5020.

For an overview of the transaction sets supported along with the releases in which they are available, go to the X12 Standards Grid

As with EDIFACT, the X12 EDI adapter does full bidirectional translation, mapping and schema-generation. And it includes the same ability to comment the XML generated from the X12 EDI source.

HL7 - Health Level 7

This is a health-related EDI standard that is currently supported through Convert-to-XML unidirectionally. The supervising organization is HL7.


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Try Stylus EDI Mapping Tools

Simplify working with Electronic Data Interchange (EDI) with Stylus Studio®'s award-winning EDI Tools — Download a free trial of our today!

Learn Stylus Studio in 6 Minutes

Can six minutes change your life? A new action-packed online video demonstration covers how to use Stylus Studio in just six minutes! Watch this video and change the way you develop XML applications forever!

Ask Someone You Know

Does your company use Stylus Studio? Do your competitors? Engineers from over 100,000 leading companies use Stylus Studio, and now you can ask someone from your own organization about their experiences using Stylus Studio.

Stylus Studio® EDIFACT Zone

Simplify your next legacy data integration project with the help of the EDIFACT Zone, the world's largest, free online reference covering all EDIFACT and UN/CEFACT versions.

Free Stylus Studio XML Training: