Data Transformation Engine Functions and Expressions Reference Guide

Chapter 3 - Function Reference PUT
Functions and Expressions Reference Guide
167
Examples
The example that follows illustrates a mapping situation in which a set of
messages is being produced in the output (output card #1). However, the
ultimate target for these messages is a message queue and the messages need
to be placed on the queue one at a time.
To accomplish this, the first output card builds the set of messages and its
Target is defined as Sink. So, this set of messages is constructed in memory,
but is discarded after the map completes. A second output card, uses the
following PUT function to put each output message (from output card# 1),
individually, on the output queue.
Message(s) = PUT ("MQS", "-QMN myqueuemgr –QN chips_queue
-T", PACKAGE (PaymentMessage:CHIPS_Payment_Message))
The first argument, MQS, identifies that the data is to be routed using the IBM
WebSphere MQ (server) adapter. The second argument,
"-QMN myqueuemgr
–QN chips_queue -T", provides the adapter commands needed by the
adapter to put the message on the queue. The third argument,
PACKAGE,
passes the data that is to be sent as the body of the message.