Showing results for 
Search instead for 
Did you mean: 

Fixed Width Formatter Generate Blank file

New Contributor III


I am using fixed width formatter in my pipeline and If I don’t have any data in the source and fixed formatter generates one output and create a blank file.
Do we have any other functionality similar to ignore empty stream.



@Rahul - unfortunately, the option doesn’t exist for this formatter snap. But there is an pattern that will resolve it. Create a child pipeline with the Fixed Width Formatter and File Writer snaps and call it with Pipeline Execute with the “Execute on” set to LOCAL_NODE and “Reuse executions” option enabled. Pipeline Execute will not be called if there are no input documents, so the formatter will not be fired to create the empty file.

I’ve attached a sample set of pipelines with this logic for your review.

You can submit an enhancement request for the snap to add the “Ignore empty stream” option via a support ticket.

Community 16931 - Child_2023_06_19.slp (4.5 KB)
Community 16931 - Fixed Width Formatter Generate Blank file_2023_06_19.slp (4.9 KB)