Page 1 of 1

Adding a header to a single file output (join all input files together) ?

Posted: Thu Feb 11, 2021 8:00 am
by DFH
Hi Simon,

Currently, there seems to be no straightforward means to add a suitable header to a single file output (join all input files together).

We have two Add header filters:
  • Add file header
  • Add restriction header
but neither of these does what's required on its own!

The difficulty is accentuated if you've no idea in advance what the individual filenames will be when they are for a pattern.

What might work would be a new Restrict filter that might be simply called Restrict to first file. Then one could use either of the above filters to add a suitable header such as a set of tab delimited titles for output lines that will be in tab delimited text format.

But then the question arises as to whether the concept should be generalised such that the proposed new filter becomes Restrict to file number[s], with the UI form for the filter the same as those for processing line numbers ?

What do you think of the suggestion?

David

Re: Adding a header to a single file output (join all input files together) ?

Posted: Wed Feb 17, 2021 9:29 am
by DataMystic Support
Hi David,

This can be easily achieved by putting the Add file header filter AFTER a merge filter.

Re: Adding a header to a single file output (join all input files together) ?

Posted: Wed Feb 17, 2021 6:48 pm
by DFH
Thanks Simon,

David