24

It seems like these are all tag syonyms:

The algorithms and tools for parsing CSV are identical to those for parsing any other delimited tabular data. In many/most programming languages and libraries, the difference between "CSV", "TSV", and any other text-delimited format is just a matter of changing an option from "," to "\t" or "\0u001F". There is almost zero reason that I can see to have these as distinct tags.

Moreover, and are overt duplicates, and even if there's an argument that the others aren't, these two certainly should be considered synonymous.

Therefore I propose that be the "primary" tag, because that is a general name for this category of file formats. All the others should be synonyms thereof.

One could argue that is more general and maybe can stand on its own. But if you look at the tagged questions, a lot of them seem to be asking about the same thing as the other 4 tags.

3
  • 6
    Supporting your argument "In many/most programming languages and libraries, the difference between "CSV", "TSV", and any other text-delimited format is just a matter of changing an option" - tsv is already a synonym of csv...
    – Tomerikoo
    Commented Aug 31, 2021 at 13:27
  • 4
    After some search, I found some sources that says that the difference between csv and dsv are not the field separator, since both can use any separator, but the behaviour of escaping. Those sources says that in csv, if escaping is needed you enclose the whole field in double quotes, while in dsv you use a escape character 1, 2
    – Magnetron
    Commented Aug 31, 2021 at 16:32
  • 2
    @Magnetron libraries for consuming csv accept both: escape characters and quoted fields.
    – Braiam
    Commented Aug 31, 2021 at 17:03

1 Answer 1

40

Honestly, despite being a little technically misleading, I think CSV should be the primary tag, since that's by far the most well-known tag and term. It has long since reached the same status as "Kleenex", "Google", "Taser", etc... specific terms for a generic thing that have basically become the generic thing term.

More often than not, someone's gonna be including the terms "CSV file" in their search queries, not "delimiter separated values file". I mean, it's not even close; has... 94 questions... and has 80,000 questions.

And the difference between creating/interpreting a CSV vs a TSV or some-other-symbol-SV file, as you've already highlighted, is just using a different character than a comma, and sometimes including headers or a final line break character at the end. I mean, the CSV file format can be used for different delimiter characters already. So if you know CSV files, you are pretty close to knowing them all; pipes, colons, carets, etc.

14
  • Yeah, [delimiter-separated-values] doesn't even have 100 questions!
    – SamB
    Commented Aug 31, 2021 at 16:50
  • 1
    I think it's not even that unusual for real software to save tab-delimited text as a .csv file anyway. I think at least some versions of Microsoft Excel do this.
    – kaya3
    Commented Aug 31, 2021 at 20:17
  • 9
    In support of this the csv tag description includes "... that lists the table fields delimited by commas or tabs or other delimiter character..." Commented Aug 31, 2021 at 20:30
  • 1
    The problem is CSV file format is not the same as the other character delimited format. You can store commas in fields in CSV despite it being the delimiter.
    – Joshua
    Commented Sep 1, 2021 at 13:40
  • @Joshua Escaping characters should be something supported for any symbol-separated-values file on some level.
    – TylerH
    Commented Sep 1, 2021 at 14:01
  • @TylerH: The tab and pipe delimited files I deal with almost daily simply can't deal with their own separator characters in the fields.
    – Joshua
    Commented Sep 1, 2021 at 14:02
  • @Joshua That sounds like an application limitation, not a file/format limitation.
    – TylerH
    Commented Sep 1, 2021 at 14:03
  • What it sounds like and what it is are two different things. I have to generate these dumb formats because people use them. I recommend the .ods format or the .json format myself but what you gonna do?
    – Joshua
    Commented Sep 1, 2021 at 14:07
  • @Joshua It is what it sounds like. CSV files support escaping characters by a number of means. If your job requires using software/end results that doesn't support that, that's the software's problem, not a shortcoming of the CSV file format itself. I can escape pipes in a pipe-delimited-file just fine (never tried with tabs because why would you, but I am pretty sure that's documented thoroughly on the internet too) while saving and parsing as a CSV.
    – TylerH
    Commented Sep 1, 2021 at 14:13
  • 1
    @Joshua ODS is XML (and JSON is obviously JSON) which are two totally different things than what this topic and tag series are about.
    – TylerH
    Commented Sep 1, 2021 at 14:14
  • @TylerH: hmdahelp.consumerfinance.gov/knowledgebase/s/article/…
    – Joshua
    Commented Sep 1, 2021 at 14:24
  • @Joshua Yep, like I said, that's not a CSV problem. It's a limitation of the HMDA platform (whatever that is), as that page clearly states.
    – TylerH
    Commented Sep 1, 2021 at 14:46
  • 1
    yes the choice of separator is not the most complex issue. However the escaping mechanism (for text fields) may be very different: using backslashes including for field separators present in the text (without necessary using start/end delimiters, using start/end delimiters but escaping them and the backslash inside by a leading backslash, doubling the delimiter. Some CSV-like format also allow escaping a newline, or allow continuation of the record on multiple lines (used for example in MIME headers using commas, taggable escapings (quoted-printable, base64, base85, UTF-7, compression...)
    – verdy_p
    Commented Sep 1, 2021 at 17:30
  • I went ahead and made synonyms without merging (yet). I've also updated the excerpt to trim out too much description and add in some usage instructions.
    – Machavity Mod
    Commented Sep 2, 2021 at 16:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .