Routing EDIFACT Documents in Productions
This chapter discusses the additional steps needed to add EDIFACT routing interfaces to a production. It includes the following topics:
Loading EDIFACT Schemas into InterSystems IRIS
Defining Routing Rule Sets for EDIFACT
When you create a routing rule set for an EDIFACT routing interface:
Defining DTL Data Transformations for EDIFACT
Your routing rules might need one or more data transformations.
When you create a DTL data transformation for EDIFACT documents:
To integrate the DTL data transformation in the production, enter its full package and class name in the Transform
field of a routing rule set
Defining EDIFACT Search Tables
Note the following points specific to EDIFACT:
Handling Repetitions in EDIFACT Documents
Some segments in EDIFACT documents can repeat or be used within loops. The repeat and loop structure can be either expressed implicitly or explicitly. InterSystems IRIS can handle either implicit or explicit repeat and loop structures, but the document must either specify all repeats and loops explicitly or all implicitly. When InterSystems IRIS is parsing an EDIFACT document and encounters the first repetition or loop, it determines whether the document is using implicit or explicit repeats. It then parses the remainder of the document using the mechanism found in the first repetition or loop. When it is parsing an EDIFACT document, InterSystems IRIS treats a mixture of explicit and implicit repeat mechanisms as an error.
If an EDIFACT document is using implicit indication of repetition, a segment is represented as a three letter label (such as UNH), followed by the data element separator and data (the data elements and components). No information explicitly indicates which repetition of a segment or a loop a particular segment is in. But if an EDIFACT document is using explicit indication of repetition, a repeating segment is expressed as the three letter label, followed by the component separator and the control numbers, followed by the data element separator. For a segment, ARA, which is a repeating segment, this may look like ARA:1+data. For a segment, DET, which is in Group 2, which is nested in Group 1, this may look like DET:1:1+data. Only those segments which can repeat or which are inside a loop are expressed using these control numbers.
By default, an EDIFACT document retains its implicit or explicit repetition indication when output to a file. You can convert an EDIFACT document with implicit indication to explicit by using the ConstructExplicitClone
method, and you can convert an EDIFACT document with explicit indication to implicit by using the ConstructExplicitClone