Excel CSV file: How to preserve double quotation mark on Unix ftp?

G

Guest

I have an Excel 2003 SP2 file with columns that contain text that includes
double quotation marks. For example: Select "Yes" to process this form.

When I save the file as a CSV file, the double quotation marks are saved.
However, when I ftp the file to a Unix server, the double quotation marks are
removed from the file.

So....how can I preserve the double quotaion marks in the file when I ftp it
to a Unix server? The only soltuion I have found is to replace each double
quotation mark with 2 single quote marks prior to ftping it, then replacing
the 2 single quote marks with a double quotation mark on the Unix server
after ftping it.

Thanks for your help!
Shannon
 
J

joeu2004

Shannona said:
I have an Excel 2003 SP2 file with columns that contain text that includes
double quotation marks. For example: Select "Yes" to process this form.
When I save the file as a CSV file, the double quotation marks are saved.
However, when I ftp the file to a Unix server, the double quotation marks are
removed from the file.

I find this observation remarkable because FTP normally knows nothing
about the structure (content) of files, except that in ASCII mode, FTP
will translate the line terminator between systems (typically LF to
CRLF and vice versa). I know for sure that this is true of UNIX FTP.
I would hope that it is also true of any MS-based FTP.
So....how can I preserve the double quotaion marks in the file when I ftp it
to a Unix server?

One idea: FTP in BINARY mode. Then on the Unix system, convert CFLF
to LF either with a sed script or a simple C program.

But again, I would be surprised that this is necessary. I wonder if
the problem is with the UNIX application that you are using -- or with
the problem description in the first place.

HTH.
 
D

Dave Peterson

You sure that excel preserves the quotes?

I'd look at that file using NotePad first.

Maybe you could write your own exporting program that would behave exactly the
way you want:

Here are three sites that you could steal some code from:

Earl Kiosterud's Text Write program:
www.smokeylake.com/excel
(or directly: http://www.smokeylake.com/excel/text_write_program.htm)

Chip Pearson's:
http://www.cpearson.com/excel/imptext.htm

J.E. McGimpsey's:
http://www.mcgimpsey.com/excel/textfiles.html


Earl's may do what you want right out of the box--he supports lots of options.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top