Real Time Information Director User Documentation
RTID Metadata Language
Hewlett-Packard Company 27 529618-002
private static final IDocSegment idocSegment =
new IDocSegment("ORDERS05", "SALES_ORDER", new TagDefinition[] {
IDOC.HEADER,
new Segment("E1EDK01", new TagDefinition[] {
new FieldElement("ACTION", "SALES_ORDER_ACTION_CD"),
new FieldElement("CURCY", "CURRENCY_CD"),
new FieldElement("WKURS", "PRICING_STATISTICS_EXCHANGE_RT"),
new FieldElement("ZTERM", "PAYMENT_TERMS_CD"),
new FieldElement("BSART", "CUSTOMER_PURCHASE_ORDER_TY"),
new FieldsElement("BELNR", new String[]
{"SALES_ORDER_NO", "PRECEDING_DOCUMENT_NO"}),
new FieldElement("BSTZD", "PURCHASE_ORDER_NUMBER_DS"),
new FieldElement("VSART", "SHIPPING_CONDITION_CD"),
new FieldElement("VSART_BEZ", "SHIPPING_CONDITION_DS"),
new FieldElement("RECIPNT_NO", "CUSTOMER_SOLD_TO_NO"),
new FieldElement("KZAZU", "ORDER_COMBINATION_IN"),
. . .
new FieldElement("DELCO", "AGREED_DELIVERY_TM")
}),
The first tag definition is IDOC.HEADER. IDOC.HEADER is statically created for you
to use in all your IDoc metadata classes and represents the EDI_DC40 header segment
illustrated in “XML IDoc Format.”
private static final IDocSegment idocSegment =
new IDocSegment("ORDERS05", "SALES_ORDER", new TagDefinition[] {
IDOC.HEADER,
new Segment("E1EDK01", new TagDefinition[] {
new FieldElement("ACTION", "SALES_ORDER_ACTION_CD"),
new FieldElement("CURCY", "CURRENCY_CD"),
new FieldElement("WKURS", "PRICING_STATISTICS_EXCHANGE_RT"),
new FieldElement("ZTERM", "PAYMENT_TERMS_CD"),
new FieldElement("BSART", "CUSTOMER_PURCHASE_ORDER_TY"),
new FieldsElement("BELNR", new String[]
{"SALES_ORDER_NO", "PRECEDING_DOCUMENT_NO"}),
new FieldElement("BSTZD", "PURCHASE_ORDER_NUMBER_DS"),
new FieldElement("VSART", "SHIPPING_CONDITION_CD"),
new FieldElement("VSART_BEZ", "SHIPPING_CONDITION_DS"),
new FieldElement("RECIPNT_NO", "CUSTOMER_SOLD_TO_NO"),
new FieldElement("KZAZU", "ORDER_COMBINATION_IN"),
. . .
new FieldElement("DELCO", "AGREED_DELIVERY_TM")
}),
The second tag definition is for the E1EDK01 segment, which also includes an array of
TagDefinition. These tag definitions define individual XML elements that are mapped to
fields in the data store. For example, the XML element tagged “ACTION” is mapped to
the field SALES_ORDER_ACTION_CD, and the “CURCY” element is mapped to the
field CURRENCY_CD.
Note: Remember that, in the case of a native document, the XML tag for a data element
is also the name of the corresponding database field. The possibility of divergence
between tag names and database field names is specific to IDoc handling.