eBiss 3

Hilfe & Dokumentation

User Tools

Site Tools


en:transformation:mappings:funktionen:allgemein:rulesetsmitwhileloop

WhileLoop for RuleSets

A new functionality for mapping rule sets is available through the RuleSetBehaviour property: By default, the value is set to AutoSelect.

As a result, the function behaves in the same way as a logical expression, i. e. the expression in the RuleSet selection field is evaluated, if this' true' results, the rules are executed within the RuleSet. However, the RuleSetBehaviour property can be switched to WhileLoop. As a result, the selection of this RuleSet is executed again and again until the expression contained in the Selection field results in' false'. Thus, the RuleSet has a loop character, analog (for i=0; i<5; i++).

Sample:

The WhileLoop setting of the RuleSetBehaviour property is required for the following task: In an EDIFACT-DESADV message, additional serial numbers for the RF-IT are to be transferred.

UNA:+.?'
UNB+UNOC:3+4035811991014:14+4035811991021:14+080315:1421+17'
UNH+18+DESADV:D:96A:UN:EAN005'
BGM+351+2013+9'
DTM+137:20080215:102'
DTM+11:20080214:102'
RFF+VN:1001'
NAD+SU+4035811991014::9'
NAD+BY+4035811991021::9'
NAD+UC+4035811991021::9'
NAD+DP+4035811991021::9'
CPS+1'
PAC+1'
PCI+33E'
LIN+1++4035811000037:EN'
QTY+12:13:PCE'
PCI+34E'
GIN+EU+4035811000037'
GIN+BN+103+104+105+106+107'
GIN+BN+108+109+110+111+112'
GIN+BN+113+114+115'
LIN+2++4035811000044:EN'
QTY+12:18:PCE'
PCI+34E'
GIN+EU+4035811000044'
GIN+BN+203+204+205+206+207'
GIN+BN+208+209+210+211+212'
GIN+BN+213+214+215+216+217'
GIN+BN+218+219+220'
CNT+2:2'
CNT+1:31'
UNT+31+18'
UNZ+1+17'

The GIN segments contain complete ranges of additional serial numbers. These must be split by a two-step transformation process (2 mappings, EDIFACT. DESADV→ Retail. Middleware. DespatchAdvice → RF-IT-Inhouse-DespatchAdvice) into items with one article each (1 x TargetPosition per piece) for the RF-IT Inhouse-Target object, so that these can be further processed by RF-IT. The unbundling of the serial number area into individual serial numbers is done by the first mapping, which maps the EDIFACT-DESADV into a MiddleWare-eBiss. Retail. DespatchAdvice. The splitting into positions with exactly one piece takes over the second mapping, which maps the data of the eBiss. retail. despatchadvice middleware into the RF-IT in-house format. The RF-IT-Inhouse Source Input (2nd Mapping Source Object, eBiss Retail. DespatchAdvice MiddleWare) Therefore, the RF-IT in-house despatch advisory mapping must have the WhileLoop setting of theRuleSetBehaviour property for the RuleSet' s_qty_cnt'. As long as the variable $cnt < is the number (@Quantity field), a new position with the quantity 1 is created in the target object of the RF-IT in-house despatch advisory mapping. If the result of this query is' false', this loop is no longer processed and no position is created in the target object. This means that the target positions are triggered per piece. The mapping for this is as follows: mappingfunktionen_allg_rulesetsmitwhileloops.jpg

en/transformation/mappings/funktionen/allgemein/rulesetsmitwhileloop.txt · Last modified: 2024/02/20 08:15 by 127.0.0.1