|
>Home>Products>DataDirect XQuery>Features>Using XML Converters
Print
Using XML Converters
A great deal of useful data is found in plain-text formats, not as XML. With DataDirect's XML Converters,
you can convert many formats to XML on the fly, so they can be queried with DataDirect XQuery. Converters are
available for EDI messages (X12, EDIFACT, and IATA), along with other formats like tab-delimited, comma-separated value, dBase files, and many more.
For instance, there are literally thousands of versions and subversions of EDI formats, and no standard way to query or process them.
XML Converters allow you to read any of these formats as XML without writing code to parse them. Consider the following EDI message:
When this is read using an XML Adapter, it is converted to the following XML (for brevity, only the first few lines are given):
An XML Converter is invoked using the doc() function. The following XQuery extracts the sender, recipient, time, and date from the EDI message.
Note that the query need not understand anything about the complex EDI format, it uses the XML structure produced by the XML Converter.
Here is the output of the above query.
|