Page 1 of 1

What is a (better) replacement for CSV-data?

Posted: Tue Jan 19, 2021 7:37 pm
by Francesco77
For my first LC-project I need a lot of data in form of vocabulary items etc.

I started to collect these data in MS-Excel which is quite convenient for gathering big amounts of data.
I then export these data in CSV-format and import it into LiveCode.

When learning how to do this I read a lot about the csv-format being obsolet and that it should not be used if possible.
Someone in this forum compared the csv-format with polio which should be eradicated :wink:

Since I do not know much about data-formats, data tables or data grids I have no idea which data-format would be better than CSV.

Which other format is recommended for the use with LiveCode?

Re: What is a (better) replacement for CSV-data?

Posted: Tue Jan 19, 2021 7:44 pm
by Klaus
Buonasera Francesco,

here a good read and a CLEVER script to overcome some inconveniences of Csv:
https://www.fourthworld.com/embassy/art ... t-die.html :-)

The best thing is to use CSV but actually saved as TSV (TABULATOR separated values).


Best

Klaus

Re: What is a (better) replacement for CSV-data?

Posted: Tue Jan 19, 2021 9:11 pm
by dunbarx
@Francesco

Hi.

What Klaus said.

CSV is problematic because commas are common characters in any dataSet, and you do not want common characters to be your delimiters. I never allow them.

Can't you keep and export your data from Excel as Tab and Return delimited text? This is what Klaus was recommending. Why, unless your data comes from another source that way, do you ever need to use CSV? And if it does, immediately replace every comma with tab.

@The whole world. Anyone have a valid reason to prefer CSV, even if you have to read data in that format?

Craig

Re: What is a (better) replacement for CSV-data?

Posted: Tue Jan 19, 2021 10:26 pm
by SparkOut
dunbarx wrote:
Tue Jan 19, 2021 9:11 pm
@The whole world. Anyone have a valid reason to prefer CSV...?
Some people may have "reasons" but none of those are valid. 8)

Re: What is a (better) replacement for CSV-data?

Posted: Tue Jan 19, 2021 11:09 pm
by bogs
dunbarx wrote:
Tue Jan 19, 2021 9:11 pm
@The whole world. Anyone have a valid reason to prefer CSV, even if you have to read data in that format?
Well, I imagine it keeping someone employed might be a valid reason ;)

Re: What is a (better) replacement for CSV-data?

Posted: Wed Jan 20, 2021 2:12 am
by dunbarx
Bogs.

You must have meant "annoyed" not "employed".

Craig

Re: What is a (better) replacement for CSV-data?

Posted: Wed Jan 20, 2021 10:53 am
by bogs
Employed to be a noid ....HEY, THATS MY JOB!!! :twisted: