On 13/06/2016 12:45, Alex Tweedly wrote:
"into an array" .... in what  way ?    presumably a numerically indexed
array.

Perhaps a more general feature requests would be to extend the 'split'
command, so that it would parse by Primary and Secondary delimiters into
numerically indexed arrays ?  (using a new optional keyword "completely"
... :-)

e.g. split completely myVar by CR and TAB

Hi Alex,

I don't think an enhancement to the split command would be adequate for correct parsing of a CSV file.

For example, this is a single line of a valid CSV file, according to some producers:

> a,"b,c",d e

The elements of the line are: "a", "b,c", "d" and "e". Obviously, this is best handled by parsing into an array.

Coping with the many subtle variants of CSV or TSV files is beyond what can be realistically built into the engine, and having a library specifically dedicated to good CSV file format support seems to me to be the best way to deal with this.

                                   Peter

--
Dr Peter Brett <peter.br...@livecode.com>
LiveCode Technical Project Manager

LiveCode 2016 Conference: https://livecode.com/edinburgh-2016/

_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to