News for hackers. Stuff that matters.
Re:All software sucks (2011) by nerdponx on Thursday August 30, 2018 @09:24AM (#17876457)
Anyone who has worked with CSV knows that it is anything but "less harmful"

Edit: I'd seen this page before, but never really appreciated the sheer arrogance of it until now. It's troll bait.

Re:All software sucks (2011) by hrktb on Thursday August 30, 2018 @09:37AM (#17876553)
Isn’t CSV one of the most used format while having no agreed/official specification whatsoever ?

I was amazed when we tried to find something to base a spec on, to help clients to read our CSV files.

Re:All software sucks (2011) by MrEfficiency on Thursday August 30, 2018 @09:34AM (#17876533)
Why is CSV bad?

I'm a huge fan of SQL, but curious what pitfalls CSV has.

Re:All software sucks (2011) by tyingq on Thursday August 30, 2018 @09:36AM (#17876544)
A pretty good summary of the sort of "deceptive simplicity" around csv: http://thomasburette.com/blog/2014/05/25/so-you-want-to-writ...

And the related HN discussion: https://news.ycombinator.com/item?id=7796268

Re:All software sucks (2011) by thomasfedb on Thursday August 30, 2018 @09:37AM (#17876554)
Not standardised. Fields that contain commas, newlines, or non-ASCII chars kill puppies.
Re:All software sucks (2011) by ainar-g on Thursday August 30, 2018 @09:54AM (#17876699)
>Not standardised.

Technically there is RFC4180[1], but yeah, CSV has a lot of flavours. I remember a story about how Excel couldn't correctly open a CSV file because it had a header that had "ID" as the first field name, and Excel's file format sniffing algorithm though that it's a different format.

[1] https://tools.ietf.org/html/rfc4180

Re:All software sucks (2011) by ChrisSD on Thursday August 30, 2018 @10:00AM (#17876758)
Technically RFC4180 isn't actually a standard but perhaps the world would be better if people could agree to treat it as such. However those living in countries that use the comma as a decimal separator may disagree.

> This memo provides information for the Internet community. It does not specify an Internet standard of any kind.

Re:All software sucks (2011) by _dps on Thursday August 30, 2018 @12:56PM (#17878294)
As someone from one of those countries I've never understood this criticism of CSV. JSON doesn't let you choose your own separator either but no one levels this complaint at it. Defensively quoting values that may contain commas is easy, and nearly always a negligible cost. This really seems like a total non-issue to me and I've never understood how it has gained so much mindshare among CSV critics.
Re:All software sucks (2011) by CodesInChaos on Thursday August 30, 2018 @01:10PM (#17878481)
The problem is Excel's horrible CSV implementation, and opening the file in Excel is one of the main applications of CSV. The German version of Excel expects semicolon separated CSV, where comma serves are decimal point and the date format must also be German. I found no way to create a CSV file that opens in Excel, regardless of locale. (And there are a million other problems in Excel's CSV implementation)
Re:All software sucks (2011) by ChrisSD on Thursday August 30, 2018 @09:44AM (#17876618)
Perhaps because there are a multitude of, sometimes ill defined or ad hoc, specifications that overlap one another in both subtle and not so subtle ways.

So you can't assume CSV files produced by one program can always be read by another.