4 ms·
I feel the simple recommendation for all CSV usecases should be "use JSON".
by slver 5y ago
I feel the simple recommendation for all CSV usecases should be "use JSON".
- JoBrad 5y agoJSON is easier for people to consume, but formats like csv can be much more efficient when comparing the amount of space used, and easier to consume for an application.
- slver 5y agoSpace doesn’t matter when most you documents are few kb. And when it does, zip it.
- JoBrad 5y agoIf you're dealing with files that small then JSON is a great solution. In the past I've used CSV to handle files that are several GB after being compressed and encrypted. Formats such as JSON would have added a lot more to the total file size.
- dragonwriter 5y ago> In the past I've used CSV to handle files that are several GB after being compressed and encrypted. Formats such as JSON would have added a lot more to the total file size. If you store tables as list of objects, sure, but that's comparing the JSON way of doing something CSV can’t handle at all (lists of heterogenous objects) to CSV doing a much simpler thing. A compact, dedicated JSON table representation (list of lists with the first list as header, or a single flat list with the header length — number of columns — as the first item, then the headers, then the data) is pretty closely comparable to CSV in size.