title: Export query to text file
body: <p>What I am trying to do is export a Tsql query to a csv file. Simple enough, however I need to be able to specify which fields are wrapped in quotes "". I can get my query to export with all the feilds wrapped. </p>
  
  <pre><code>"SCHEN001","Joe Bloggs Inc","1","1","1","1","1","1","13","6","Mr John Smith"
  </code></pre>
  
  <p>What I would like to export is</p>
  
  <pre><code>"SCHEN001","Joe Bloggs Inc",1,1,1,1,1,1,13,6,"Mr John Smith"
  </code></pre>
  
  <p>Is this possible using Tsql?</p>
  
  <p>Any ideas would be greatly appreciated</p>