Real Time Information Director User Documentation
RTID Metadata Language
Hewlett-Packard Company 35 529618-002
public SegmentQualifier(String qualifierValue, FieldElement tag)
Examples:
In the following example, an array of tag definitions (in this case FieldElement) specifies
how to map two data elements if the qualifier has the value “025”:
new SegmentQualifier("025", new FieldElement[] {
new FieldElement("DATUM", "RECORD_CREATE_DT"),
new FieldElement("UZEIT", "ORDER_ENTRY_TM")
})
In the following example, if the qualifier has the value “ZZV,” the data elements
BELNR, ZEILE, and DATUM are mapped to the columns SUBSEQUENT_DOC_NO,
DOCUMENT_ITEM_NO, and RECORD_CREATE_DT, respectively. In addition, the
value “V” is stored in the SUBSEQUENT_DOCUMENT_CG column.
new SegmentQualifier("ZZV",
new ImpliedField("SUBSEQUENT_DOCUMENT_CG","V"),
new TagDefinition[] {
new FieldElement("BELNR", "SUBSEQUENT_DOC_NO"),
new FieldElement("ZEILE", "DOCUMENT_ITEM_NO"),
new FieldElement("DATUM", "RECORD_CREATE_DT")
})
Record Segments
Here is another excerpt from the ORDERS05 format metadata. This excerpt illustrates
the definition of a record segment.
The significance of a record segment on input is that, if the document contains the
specified tag (that is, the specified segment), a record is written to the specified table. In
this example, each instance of segment E1EDP01 in an inbound document causes a
record to be inserted into the SALES_ORDER_DETAIL table.
Conversely, if an ORDERS05 IDoc is generated as output, one E1EDP01 segment will
be generated in the outbound document for each order-detail record in the table that has
the same keys as the SALES_ORDER.
new RecordSegment("E1EDP01","SALES_ORDER_DETAIL",new TagDefinition[]{
new FieldsElement("POSEX", new String[]
{"SALES_ORDER_ITEM_NO","PRECEDING_DOCUMENT_ITEM_NO"}, IDOC.ITEM_NO),
new FieldElement("ACTION", "SALES_ORDER_ITEM_ACTION_CD"),
…
new RecordSegment("E1EDP20","SLS_ORD_SCHEDULE_DT",new TagDefinition[]{
new FieldElement("WMENG", "CONFIRMED_QT"),
new FieldElement("EDATU", "SCHEDULE_LINE_DT"),
new FieldElement("EZEIT", "DELIVERY_TM"),
new Segment("ZEEDP20", new FieldElement[] {
new FieldElement("ETENR", "SCHEDULE_LINE_NO",
IDOC.LINE_NO),