Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CSV and double quotes
Message
De
21/04/2015 19:36:48
 
 
À
20/04/2015 11:51:43
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows 7
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01618070
Message ID:
01618929
Vues:
46
>>>>>>>>>Over the last 20+ years I had to export, and more frequently import, data in various text formats, and the most frequent situation was that I had to reverse engineer that contract, i.e. to guess the rules used to create the text. The most frequent solution was something beginning with FileToStr()... and a lot of chrtran(), strtran(), aLines(). Append from... works only for simplest cases, which were always rare.
>>>>>>>>
>>>>>>>>Dragan, that's a long text, but was I miss is your admission that VFP's implementation contains a bug.
>>>>>>>
>>>>>>>Doesn't import from a loosely defined format in absolutely all cases? That's missing a feature, not really a bug. Such bugs can be found in all kinds of attempts to convey data in plain text format. I've seen Excel do crazy things with csv files, so what. The format has limitations, implementor beware.
>>>>>>
>>>>>>It is not missing a feature. It is a bug, simple as that. What is it that people here don't admit this??? There must be a deeper motive for that type of denial.
>>>>>>
>>>>>>Also keep in mind that not only the company where I'm currently working is upgrading their MS SQL Server version. So, this bug will gonna hit many more developers.
>>>>>
>>>>>The very idea that a text file can be trusted to carry data, delimited by characters that may be expected to exist inside the data, is the initial bug.
>>>>
>>>>What a nonsense! The COPY TO CSV should have added the second double quote. THERE is the bug.
>>>>
>>>>
>>>>> Everything else is a blind implementation of that idea. Anything trying to implement that without a firm contract between the sender and recipient will be buggy.
>>>>>
>>>>>In this case, the bug is in the "copy to effe type csv" command - it produces this:
>>>>>
txt
>>>>>"is weer "ziek""
>>>>>i.e. it blindly wraps quotation marks around a string containing quotation marks. It doesn't even have a contract with itself. That, yes, that is a bug.
>>>>
>>>>Again, what a nonsense! The APPEND FROM CSV should have converted the double double quotes to a single double quote. THERE is the accompanying bug.
>>>
>>>OMIPU
>>>
>>>Stop complaining. File it to MS. Possibly they will recreate the VFP team to do a bug fix for you.
>>
>>Sorry, I don't know what omipu means. But I'm sure it is not a compliment. About 'complaining': I'm not complaining at all. I'm merely trying to make the readers aware of the fact that there is a lot of denial here and that the bug is a bug is a bug, simple as that. And as I wrote, more developers will gonna get complaints of customers when they upgrade to the latest (?) version of SQL Server. They then search here on the UT and then it's a good thing they read that it's a bug and what workaround is the best way to go.
>
>Oh My Invisible Pink Unicorn

>Just distress.
>
>And no, this is not a bug. This is the way it is implemented.

Okay master.

>And do not talk SQL server if you mean M$ SQL Server. This is somthing different.

Yes master.
Groet,
Peter de Valença

Constructive frustration is the breeding ground of genius.
If there’s no willingness to moderate for the sake of good debate, then I have no willingness to debate at all.
Let's develop superb standards that will end the holy wars.
"There are three types of people: Alphas and Betas", said the beta decisively.
If you find this message rude or offensive or stupid, please take a step away from the keyboard and try to think calmly about an eventual a possible alternative explanation of my message.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform