Excellent point about the decimal separator. --
rk -----Original Message----- From: ProfoxTech <profoxtech-boun...@leafe.com> On Behalf Of António Tavares Lopes Sent: Friday, April 16, 2021 12:48 PM To: profoxt...@leafe.com Subject: Re: Variations in CSV settings by region The problem is mainly due to the symbol used as a decimal separator. In most of the European countries, that will be the comma, not a period. Separating values with commas won't work well in this scenario, hence the need to use a different symbol to separate values (HTab, semi-colons, something else). Imagine how a "C"SV document would look like if the value separator was a period. This type of problem is addressed in the CSVProcessor class. To handle a typical European scenario: m.CSV = CREATEOBJECT("CSVProcessor") m.CSV.ValueSeparator = ";" m.CSV.DecimalPoint = "," * other properties that may be important * .WorkArea, .HeaderRow, .SkipRows, .DatePattern, .NullValue, ... m.Result = m.CSV.Import(GETFILE("csv")) On Fri, Apr 16, 2021 at 5:27 PM Richard Kaye <rk...@invaluable.com> wrote: > Well, technically there is a defined standard for CSV but how well > various applications conform to it is another question, Frank. The > problem is the customer has full control over what they do but > generally none of them are tech geeks like us. 😊 > > We have well-defined import column definitions in our application or > in some cases we are consuming known formats coming from 3rd parties. > But we are very US-centric and that doesn't really help our > international customers in regions where the field and text delimiters are > different. > Most of them have enough Excel skills to do a Save As. Yes, we could > tell them to use different formats, like TAB delimited or straight-up XLSX, > etc. > But then I'm rewriting the import stuff which was built to use the > allegedly standard CSV format. Before doing that I figured ask the > ProFox community about what how they have handled this. > > -- > > rk > > -----Original Message----- > From: ProfoxTech <profoxtech-boun...@leafe.com> On Behalf Of Frank > Cazabon > Sent: Friday, April 16, 2021 10:45 AM > To: profoxt...@leafe.com > Subject: Re: Variations in CSV settings by region > > I have never seen a standard when it comes to CSV. I have stopped > using Excel and use Libre Office and when I try to save a file as CSV > it prompts for Character set, field delimiter and String delimiter. > > Would the issue go away if you specified a tab as your field delimiter > and no string delimiter? Or do your customers have no control over the > production of the files? > > Frank. [excessive quoting removed by server] _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: https://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: https://leafe.com/archives This message: https://leafe.com/archives/byMID/cadj74tfyyuuc1gd4uvksxfjcusnvvjr5sz8hhid3o1rdn-a...@mail.gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious. Report [OT] Abuse: http://leafe.com/reportAbuse/cadj74tfyyuuc1gd4uvksxfjcusnvvjr5sz8hhid3o1rdn-a...@mail.gmail.com _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: https://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: https://leafe.com/archives This message: https://leafe.com/archives/byMID/mwhpr1001mb2144924a00bb577608a6212ad2...@mwhpr1001mb2144.namprd10.prod.outlook.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.