News for hackers. Stuff that matters.
Re:Friends don't let friends export to CSV by hn_throwaway_99 on Monday March 25, 2024 @10:34PM (#39823753)
I can't remember the last time I, or anyone I've ever worked with for that matter, ever typed up a CSV from scratch. The whole point of USV is that the delimiters can't normally be typed so you don't have to worry about escaping.

USV supports displayable delimiters (see https://github.com/SixArm/usv), so for the much more common case of editing an existing CSV in a text editor, you can just copy and paste.

Re:Friends don't let friends export to CSV by albert_e on Monday March 25, 2024 @11:24PM (#39824005)
Everyone of us was a beginner at some point. The first time we came across CSV format we likely typed it in notepad by hand. A lot of issues with CSVs are also sometimes troubleshooted by hand-- by manually fixing a quote or a comma.

There is value is the ability to do this level of editing and troubleshooting.

Re:Friends don't let friends export to CSV by hn_throwaway_99 on Monday March 25, 2024 @11:44PM (#39824083)
> The first time we came across CSV format we likely typed it in notepad by hand.

Again, I'm not saying CSVs aren't edited by hand in a text editor, I'm saying they aren't created from scratch in a text editor, even by beginners. USVs are easy to edit in a text editor, too, and I tried viewing and editing USVs with a couple different fonts and had no problems.

Re:Friends don't let friends export to CSV by iainmerrick on Tuesday March 26, 2024 @04:54AM (#39825564)
If the separators can't easily be typed, how do you add a new cell?
Re:Friends don't let friends export to CSV by scbrg on Tuesday March 26, 2024 @08:31AM (#39827033)
Nobody can type up a GIF image, or Word document in a Notepad, yet files of both those formats exist. The answer obviously is tooling. If a format with sane separators was common, so would editors that could edit that format be.
Re:Friends don't let friends export to CSV by iainmerrick on Tuesday March 26, 2024 @08:52AM (#39827223)
I was responding to the GP's:

USVs are easy to edit in a text editor

I don't see how that's the case.

If a format with sane separators was common, so would editors that could edit that format be

Sure, but that's a hypothetical future editor, not something that currently exists.

Edit to add: I also disagree with "sane" in that context. New separators won't solve anything. You'll always need escaping/encoding/encapsulation; get that right and everything else follows. JSON is comma-separated and does just fine.

Re:Friends don't let friends export to CSV by hn_throwaway_99 on Tuesday March 26, 2024 @09:50AM (#39827815)
Copy and paste.
Re:Friends don't let friends export to CSV by eviks on Tuesday March 26, 2024 @02:29AM (#39824779)
No we didn't, we likely typed in Excel by double clicking on our first csv
Re:Friends don't let friends export to CSV by hnlmorg on Tuesday March 26, 2024 @03:35AM (#39825089)
I can’t speak for everyone, but I definitely didn’t use Excel.
Re:Friends don't let friends export to CSV by Dalewyn on Monday March 25, 2024 @10:37PM (#39823774)
I've valued the virtue of CSVs being readable by any text editor known to man, and I've occasionally edited them by hand. The pure simplicity of reading and typing commas trumps any value provided by more esoteric configurations.

As for escaping, that's for the subsequent programmers (which could also be me) to figure out. If it is me, I'll deal with it because it keeps things simple.

Re:Friends don't let friends export to CSV by groestl on Tuesday March 26, 2024 @05:10AM (#39825667)
> I've occasionally edited them by hand.

Yeah, usually when the quoting was f'up.