title: Prevent extra characters in text file when using Powershell cmdlet export-csv
body: <p>I'm using the Powershell cmdlet export-csv to export the results of a sqlserver query to a .txt file. The result rows match my expectations when I view them with a text editor (Notepad), like this:</p>
  
  <pre><code> Account|Representative|Note
  </code></pre>
  
  <p>But, when I open the file using Binary file format (in TextPad), I see that the result rows are interspersed with extra characters (not sure if they are periods or spaces), like this:</p>
  
  <pre><code> A.c.c.o.u.n.t.|.R.e.p.r.e.s.e.n.t.a.t.i.v.e.|.N.o.t.e.
  </code></pre>
  
  <p>I've tried specifying different values for export-csv's encoding parameter, including UTF32, UTF8, ASCII, and Unicode, but can't get rid of the extra characters.</p>
  
  <p>I have other methods of generating the file (SSIS package), but would specifically like to get this Powershell option working for the benefit of the group that will support the export.</p>
  
  <p>Thank you in advance for any help you can provide.</p>