Writing Flat Data to a Variable Format File
In a Spectrum Technology Platform dataflow each record has the same fields. However, in a variable format file, not all records contain the same fields. In order to write flat data from a dataflow to a variable format file you need to break up each record in the dataflow, grouping the fields from each record into list fields corresponding to the record types you want to use for the variable format file. A list field is a collection of fields. For example, the fields FirstName, LastName, Gender, Address, and Phone could be grouped together into a list field called AccountOwner.
To write flat data to a variable format file, use an Aggregator stage to group fields into list fields corresponding to the record types you want to write to the variable format file. To do this:
The fields coming out of the Aggregator stage are now grouped into list fields that correspond to the record types you want to include in the variable format file output.
For example, given this flat data:
FIRSTNAME,LASTNAME,ADDRESS,ACCOUNTNUMBER,DATE_OPENED,TRANSACTION_NUMBER,TRANSACTION_DATE,AMOUNT
Joe,Smith,100 Main St,CHK12904567,12/2/2007,1000567,1/5/2012,323.12
You would want to convert it to something like this in the variable format file:
AccountOwner Joe,Smith,100 Main St
AccountInformation CHK12904567,12/2/2007
Transaction 1000567,1/5/2012,323.12
To accomplish this, you would create an Aggregator stage that is configured like this: