Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CSV with double quotes
Message
De
06/03/2017 14:15:47
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
CSV with double quotes
Divers
Thread ID:
01648804
Message ID:
01648804
Vues:
81
We have an old system which exports a set of records to an XLS spreadsheet. Because of the record limitation in COPY XLS we export the table in chunks of 60,000 records. Currently, this means three separate spreadsheets are exported.

The user has requested that only one file be generated.

I did a COPY TO CSV. But that runs into issues because some of the fields have embedded double-quote characters in the value. For example, a description field that is
width = 5" and height = 5.5" and color = "red"
and the double-quote is breaking the intended format of the result.

I could probably write something that opens an instance of Excel and then writes cell by cell, but that has a different set of issues.

I can also go through the table and CHRTRAN the double-quotes into a pair of double-quotes. That seems to clear the immediate issue.

Is there some other "COPY" or "EXPORT" command that I can use to get the desired result? Or some completely different process?

All advice welcome.

............Rich
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform