Toad World® Forums

Toad - Save Output as CSV - Issue in data with embedded Comma


#1

Hi Team,

My requirement: Save the output of a query into Excel.
Limitations: My query results are more than 65K.

Method tried: Save it as CSV - Open CSV - Convert Text to Columns - Save as Excel

Issue Description:
I saved the result of a Toad query as a .CSV file ( Export Format: Delimited Text File and saved the file with .CSV extension). The delimilter used was PIPE (|). I also tried with Semi Colon (;).

My query results have the following columns -
Col_1, Col_2, Col_3, Col_4

Col_3 has data which has comma in it in few rows. (Ex: aaaaaa,dddddd)

When I open the CSV file, all rows which does not have comma in Col_3 have it’s entire data in the first field in the excel.

But, those rows with a comma in Col_3 have it’s data splitted into two fields.

This jeopardizes my results when I do a “Text to Columns” feature.

Question: Why Toad considers my Comma (embedded in Col_3) and saves it in a separate field when saving it as a CSV though my delimiter is PIPE or Semi Colon.

Thanks in advance for your help

Cheers,
Anand