Write column names to the first row of a flat file target

Writing column names in the first row of a flat file target using PowerCenter (version 8.1 or update) session, do the following:

  1. Edit the session with the flat file target in Workflow Manager.
  2. Select the Mapping tab.
  3. Select the target file.
  4. Scroll to the Header Options attribute.
  5. Select Output Field Names from the attribute list.



By default, this option is set to No Header.

When this option is selected, the server writes the target definition port names to the flat file target in the first line, starting with the hash symbol (‘#’).


More Information

Remove the hash symbol from the flat file header in PowerCenter

Covid 19
COVID-19: Digital Insights For Enterprise Action

Access Perficient’s latest insights into how you can leverage digital technologies to not only respond to the pandemic, but drive your operations forward and deliver experiences your customers need.

Get Informed

 There are two methods:

1. Starting from PowerCenter 9.1.0 Hot Fix4:  an undocumented custom flag RemoveOutputHeaderHash has been added. To remove the hash from the flat file header, set the RemoveOutputHeaderHash flag to Yes


2. Use the Power Center session “Header Command” output option: In target properties, for Header Options, select ‘Use header command output’. For the Header Command uses ECHO (Windows) or CAT (UNIX) and paste the column names into the header command line. This must include the names of the columns in the correct order separated by the correct number of spaces (fixed width target) or by the correct delimiter (delimited file).


Use header command output and the following Header command:


With this setting the target file is written as follows:


User1, 01
User2, 02
User3, 03



About the Author

More from this Author

Thoughts on “Write column names to the first row of a flat file target”

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Subscribe to the Weekly Blog Digest:

Sign Up