Inhaltsverzeichnis

Automatically add key/value pairs

Introduction

When transforming incoming or outgoing documents, we often need a so-called recoding or translation of proper or foreign keys. For this purpose, value tables and value providers are usually created. Normally a trader does this when receiving PRICATs1). Here then e.g. the commodity groups, colors and sizes data of the Liefaranten on the own keys are translated. For this a value provider was created for each attribute which contains all known keys ideally with designation. In addition a value table was prepared, which is used depending upon requirement global or partner-specifically. All this is already explained in detail in the HowTo vorbereitung.

Procedure

If you want to fill the value provider and value table automatically with content, the following preparations are necessary:

  1. a suitable documenttype for the transfer of the key-value pairs
  2. a suitable receiving_channel
  3. a job A to open the receive channel and delegate to job B
  4. a job B to analyze and select the document type
  5. a mapping with the document type as source and target object2). In this mapping the function AddLookupKeyValue() is used to create the value provider with the new key3) and the value table with the values to be translated and their assignment to the return value from the value provider.
  6. a Automation to start the Job A
1)
price and catalog information of a commodity.
2)
This is actually only needed to formally fulfill the completeness of a mapping
3)
The value which should be returned as a result of a LookUp function.