5 ms·
This is actually a very elegant way of formalizing CSV. For most apps, if you were to simply output "CSV files" using this encoding, really no one consuming the
by gregmac 10y ago
This is actually a very elegant way of formalizing CSV. For most apps, if you were to simply output "CSV files" using this encoding, really no one consuming them would know any different -- except you could actually point them at a spec being used.
I've been in arguments with customers before where they complained we were quoting strings, and CSV files shouldn't have quotes, and it would have been nice to say "We're using CSJ, please just parse that way".
I think the name is perhaps misleading though, as it sounds more like it's a variant of JSON than a formalization of CSV. Perhaps "JSON flavored CSV" would be more appropriate?
- LukeShu 10y agoI mean, you could always point them to RFC 4180.
- gregmac 10y agoAh, well, look at that. Thankfully I haven't had to deal with CSV files for several years, though I wish I knew about that RFC at the time. Thanks.
- gregmac 10y agoOkay talk about ironic. Yesterday in our ops meeting, it came up that some tool another department had built was exporting csv "with extra quotes that were causing problems" (I've had no involvement in any of this). My ears perked up remembering this comment and I was able to point out this RFC, so hopefully it will save them some time in arguing about csv formatting. Thanks!
- astrodust 10y ago"Comma-Separated JSON" implies objects, "object-notation" is integral to the definition. What about "Comma-Separated JSON Values"? CSJV!