eBiss 3

Hilfe & Dokumentation

User Tools

Site Tools


en:transformation:mappings:funktionen:abfragefunktionen:lookup:addlookupkeyvalue

AddLookupKeyValue

The function AddLookupKeyValue () creates the value, if it does not yet exist, as Value-Provider1) and assigns it to the LookupTableKey, or changes the value if LookupTableKey exists.

Note: Existing lookup key-value pairs are updated with the new value.

Note: This function is inactive in the DEBUG mode.

Syntax:

AddLookupKeyValue('LookupTable', 'LookupTableKey', 'ValueProviderValue')

Sample 1:

AddLookupKeyValue('Manufactorer-Retailer-Color', '47A11', '992855')

Sample 2:

With this function you can e. g. Temporarily store information in the converter that cannot be processed by a host system. The trading partner sends ORDERS with a specific reference that is not in the ORDERS (INHOUSE) space.

preconditions: Create a Value-Provider2) to which the references can be added. Then, create a Lookup table types and assign the values from Value-Provider3) to it. Then create a new LookupTable. Give these objects a descriptive name (here in the example' MyLookUpTableName' is used for all objects).

The reference can now be created with a unique key as a new lookup entry as follows:

AddLookupKeyValue('MyLookUpTableName', concat($LocationGLN,$DocNumber), SG_1/RFF/DG_C506[@DE_1153='CR']/@DE_1154)

This reference can then be read out during the transformation of eBiss.Industry.DespatchAdvise to eBiss.MappingObjects.Edifact.D96A.Messages.DESADV.DESADV by restoring the unique key with e. g.:

concat(@DeliveryPartyGLN,@ReferenceBuyerOrder)

and with and therefore with:

LookupGlobalValue('concat(@DeliveryPartyGLN,@ReferenceBuyerOrder)',$RFF_CR)

and can thus be written away at the desired position in the target object.

Note: AddLookupKeyValue() can also be added to the Writing Functions

1)
ValueProvider Entry
2) , 3)
ValueProvider
en/transformation/mappings/funktionen/abfragefunktionen/lookup/addlookupkeyvalue.txt · Last modified: 2024/02/20 08:15 by 127.0.0.1