Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2003

    Unanswered: BCP OUT with Double Quote(") text qualifier?

    How do I tell BCP that I want it to output with Double Quotes around my char fields?

    It's easy to do in DTS by setting the connection properties of the Text File destination. The reason I can't use DTS is because my table has 329 fields and when I try to modify the destination properties of the transform task, Enterprise Manager bombs. I'd rather use BCP and a format file anyway.


    Ray Metz
    Everett, WA

  2. #2
    Join Date
    Feb 2002
    Houston, TX
    I just tried using a format file to define the field seperators as "," but BCP barfed. when I switched to ',' it worked. Maybe you could use this.
    Paul Young
    (Knowledge is power! Get some!)

  3. #3
    Join Date
    Jul 2003


    Yeah, I had a similar idea to create a view with select '"' + field + '"' for each of the char columns. But since my export has over 300 columns and many of them char or varchar, I wanted an easier solution than going through each column.

    Luckily, the Oracle DBA on the other end was ok with me not sending the quotes. The field seperator was a bar (|), and so far we haven't found any bars in the data so I think we're in good shape.

    Thanks for your reply.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts