Originally posted by: Rich_McFate
Let's assume you have two kinds of records -- B and C. Each has, as it's last element, an item called RowCount. You can probably get what you want as follows:
BRecord = F_Map1(<arglist>, RowCount
Last IN <outputcardname> + 1)
CRecord = F_Map2(<arglist>, RowCount
Last IN <outputcardname> + 1)
(Note: assumes that RowCount is numeric.)
If the items in each record are different, then simply change the second rule:
Crecord = F_Map2(<arglist>, Count(Brecord:cardname) + Index($) )
Your mileage may vary depending upon your target structure, but...
I'm confident you won't need to mess around with custom functions. And don't even
think about trying to use the GETANDSET function to maintain an external counter. It's theoretically possible, but I've never seen it work as well as alternative approaches.
#IBM-Websphere-Transformation-Extender#IBMSterlingTransformationExtender#DataExchange