Processing SWIFT messages with variant fields

Use Copy Type to distinguish between variant fields with identical node names in a SWIFT message.

About this task

SWIFT messages can contain variant field numbers. For example, an MT103 message (Credit Transfer Payment Instruction) can include field 50A (Ordering Customer). However, the actual message that is received might be designated as 50A, 50F, or 50K, all of which have the same node name of "Ordering Customer." To distinguish between these variants, called meta types, save the type to a tag on the Store page.

Procedure

  1. Create a test that includes a Subscribe action.
  2. Format the message to use the SWIFT schema with a message type that includes meta types.
    For more information, see Applying the SWIFT schema to a message.
    For example, the MT940 message type (Customer Statement Message) has variants for the Closing Balance field (62F or 62M).
  3. In the message editor, open the Field Editor by double-clicking the field that has variants.
  4. On the Filter page, click New to add an action. Set the Action Type to Type and the Variant to Meta Type.
    These settings ensure that the incoming data is compared to the meta type only.
    The Filter page of the Field Editor, with a Type action set for Meta Type.
  5. In most cases, you want to save both the contents of the field (the data) and the meta type. First, create a line to save the data. On the Store page of the Field Editor, provide the information in the following table.
    Table 1. Fields for data
    Field Example Description
    Action Type Copy Saves the contents of the field
    Description Closing Balance data Provides a reminder of tag contents
    Tag Closing Balance Creates a tag with the specified name
    When you complete these fields, click New. A line is added to the display.
    Note: The first time that the Store page is displayed, the Action Type, Description, and Tag fields are not displayed. Click New to display the fields, which contain default Copy Data information. Overwrite those fields with the information shown in the table and click New again. Two lines are now displayed. Highlight the line that contains the default data and click Delete.
  6. Next, create a line to save the meta type. Overwrite the information that you just entered with the values in the following table.
    Table 2. Fields for data
    Field Example Description
    Action Type Copy Type Saves the meta type of the field
    Description Closing Balance meta type Provides a reminder of tag contents
    Tag Closing Balance Type Creates a tag with the specified name
    When you complete these fields, click New. A second line is added to the display.
    The Store page of the Field Editor, with a Copy Type action.
    When you finish changing the Store page, click OK.
  7. On the Steps page of the test, add a Decision action to test the tag you created in step 6.
    The following example tests the MT940 message variants:
    tags["Closing Balance Type"]=="62F";
    Save the test before you run it.