We need to create a condition for each of our interface fields that prevents them from receiving null values from the application.
- From the
Mappings pane, right-click
ElementKey(*), then click
Apply Condition on the popup menu.
- In the
New Name field, type
KeyNotNull, then click
Create.
- From the
Field drop-down list, click
RETURN-GRP1.FLD0015Grp(14).
- In the
Field field, replace the
14 with an asterisk to represent all occurrences.
- From the
Operator drop-down list, click
>=.
- In the
Field or Literal value field, type
" " (double-quote followed by a space and another double-quote); then click
OK to close the Condition Editor, and
OK again to close the Apply Condition dialog box.
This condition mandates that only data that has a value greater than or equal to a space can be moved from
RETURN-GRP1.FLD0015Grp(*) to
ElementKey(*). We need to apply a similar condition to the other mapping.
- From the
Mappings pane, right-click
ElementValue(*), then click
Apply Condition on the popup menu.
Because the condition we're creating here is so similar to the condition we created for ElementKey, we can use the condition we created for ElementKey as a starting point.
- From the
Existing Condition drop-down list, click
KeyNotNull.
- In the
New Name field, type
ValueNotNull, then click
Create.
- From the
Field drop-down list, click
RETURN-GRP1.FLD0016Grp(14).
- In the
Field field, replace the
14 with an asterisk to represent all occurrences.
The rest of the condition definition is the same as for KeyNotNull and is already populated in the appropriate fields.
- Click
OK to close the Condition Editor; then click
OK to return to the
Interface Mapper.
The
Condition column in the
Mappings pane now shows the conditions you defined.
- Save the service interface without exiting the
Interface Mapper.