Adding Pipe Delimited Option for Report Rendering

One of my customers created a report used to send data to another system via a file transfer.  The problem is the transfer is not direct and requires a process to convert the CSV to pipe delimited.  The system receiving the data has a format it expects that isn’t configurable and must be pipe delimited.  Reporting Services comes with the ability to export a comma delimited out of the box, but that’s the only text file option by default.

After a little chat with Mr. Google I found that adding a new data rendering extension in SSRS is quite simple and any text file output you may want is just a change to the reportserver.config file away.

Add the following snippet to your <Render> node:

      <Extension Name="PIPE" Type="Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport,Microsoft.ReportingServices.DataRendering">
        <OverrideNames>
            <Name Language="en-US">TXT (Pipe delimited)</Name>
        </OverrideNames>
        <Configuration>
          <DeviceInfo>
            <FieldDelimiter>|</FieldDelimiter>
            <FileExtension>txt</FileExtension>
          </DeviceInfo>
        </Configuration>
      </Extension>

Another thing, once the rendering extension is added it can be accessed from all interfaces.

  • This rendering format can be called from the ReportManager application as you see in the screenshot.

  • It can be used in file share delivery for your subscriptions
  • It can be used as a rendering option in custom URLs you create to run reports from other applications using the following command in the URL: &rs:Format=PIPE&rs:Command=Render

The Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport has numerous configuration options, pipe delimited is just one, so customize away!

4 Responses to Adding Pipe Delimited Option for Report Rendering

  1. Prajakta J says:

    Hi David,
    I am stuck wherein your post can help me. I included the above code into .config file, but not able to see the newly added rendering option in report. I know this post is old, do we need to follow any other way to get this implemented into SQL Server 2008 R2?
    I am actutally looking an option to export the report into .txt file format.
    Your help will be appreciated
    Thanks,
    Prajakta J

  2. I didn’t mention in the post but you will need to restart the SSRS service for the change to take effect.

  3. bibek says:

    This worked perfectly. Thanks a bunch !

  4. SSRS Developer says:

    Hi David,
    this works like charm! Thank you! But after exporting the data, I noticed that there is a blank row at the bottom of the file. Do you know how to remove it? This is happening for All reports.

Leave a Reply

Your email address will not be published. Required fields are marked *