I have a process that I am trying to duplicate from SQL Integration Services (SSIS) into Ensemble so that the rest of my team can help support any issues that may happen.

This particular job creates multiple dictionary files, but for each one of the dictionary files it creates, it also creates a control file that tells the vendor what to process.

So example....I have a result set that is written to a.txt but I also need to create a a.ctrl, then I will have a b.txt and need a b.ctrl.

Using only one EnsLib.RecordMap.Operation.BatchFileOperation  for the control files, is it possible to pass the File Path and File Name from a Business Process(BPL) to a single EnsLib.RecordMap.Operation.BatchFileOperation to write multiple ctrl files.



Scott Roth

Integration - Interfaces

The Ohio State University Wexner Medical Center

  • 0
  • 71
  • 0
  • 1


You may pass in a filename from a BPL by setting the %Source of the message being passed from the BPL to the Operation.  Then in the filespec use the %f to pick up this name.   Note that you may still add timestamps, etc. in the filespec so the passed name in %Source may be a partial of the final filename.   

If you have used a recordmap service to read the file the %Source within the message from the service will be set to the original filename and usually includes the full path as well.  One usefulness for this original filename is to utilize it to have corresponding names for processed batches on the output files.

This will NOT allow the passing of a File Path or even a partial path.  If a path is included with the filename it will be striped before applying to the %f in the filespec of the operation.  A custom operation would need to be coded in order to dynamically set the path.

You need to be very specific when utilizing this with Batch operations because if the filename is changed mid batch it may be considered as a different batch and thus not properly write out if "Batch rollover" is used.   If an "End of Batch" message is being sent from the BPL instead of utilizing the rollover time then it would end the batch for the filename in %Source.   (Note that some testing would be needed to confirm this behavior)

If sending to a different path it is easiest to have a different operation and route to the correct operation within the BPL.