title: Trim before destination write in SSIS?
body: <p>I have a dataflow, where there is a DB source and a flat text file destination(delimited by pipe '|').
  The DB source is picking up the SQL query from a variable.</p>
  
  <p>Problem is that if my DB field size of say, firstname and lastname are 30 characters, i get the output as(space represented by dots)</p>
  
  <p><code>
  saurabh......................|kumar.......................
  </code></p>
  
  <p>What I need is the fields to be trimmed, so that the actual output is</p>
  
  <p><code>saurabh|kumar</code></p>
  
  <p>I have more than 40 columns to write, and I would not want to manually insert <code>RTRIM</code> after every column in my BIG sql query :(</p>
  
  <p>I should add that the source can have upto 50,000 rows returned. I was thinking of putting a script component in between, but processing every row might have a performance impact.</p>
  
  <p>Any ideas?</p>