Parse a CSV File with Regular Expressions

Alejandro Tejada capellan2000 at
Tue Jan 18 14:09:57 EST 2005

Hi Developers,

I've read this series of messages with a lot
of interest, because parsing, modifying and
saving foreign data within RunRev is a
daily task for most computer programmers...

but, i keep wondering about the kind of data
that you are talking about: comma separated values

I know that csv are simple text files.
If i change a simple character within a binary file,
surely MOST of the applications will refuse to
open the file.

It's not possible to check if the entire file
is a valid comma separated value archive,
before processing????

For example, checking the number of
comma separated items in every line and flag
and error if there is a deviation... 

Some apps identify themselves in the archive
they write. (I know that Adobe ilustrator and pdf
files had a tag to identify the creator
of the files)
IF every application that export data as csv, 
identify themselves, developers could use 
different code to parse the file.

Which apps identify themselves in the cvs data????

And finally...
The apps that exports data as cvs, must provide
some way to convert this comma character within
the record of the exported data... or maybe not. 


Which apps do have or not have the "KNOW-HOW" 
to export data as cvs correctly????

Thanks in advance for your answers! :-)


Visit my site:

Do you Yahoo!? 
The all-new My Yahoo! - What will yours do? 

More information about the Use-livecode mailing list