A product description with an inch mark, like a 55" screen, makes the conversion fail. What is the fix?
Inside a field wrapped in double quotes, every quote character must be written twice, so 55" becomes 55"". The converter stops and names the row rather than guessing where the cell ends. If the field is not wrapped in quotes at all, the same mark is read as an ordinary character and nothing fails.
Why one mark confuses the whole file
In CSV a double quote says 'everything between these marks is one cell, even if it contains commas or line breaks'. When a field opens with a quote, the reader looks for the quote that closes it. If it meets the inch mark of a screen size halfway through, it cannot tell whether that is the end of the cell or part of the text.
The agreed rule that settles this is simple: a quote inside a quoted field is written doubled, "", and a single one means the field is closing.
Three cases we ran through the tool
Case one, a quoted field with a single mark inside:
name,size
TV,"55" screen"
Result: the conversion stopped with 'Row 2: a quote inside a quoted field is not doubled.' Case two, the same field with no quotes around it:
name,size
TV,55" screen
Result: it converted, and size came out as '55" screen'. Case three, a quoted field with the mark doubled:
name,size
TV,"55"" screen"
Result: it converted to the same value, '55" screen', because the doubled quotes turned back into one.
How to fix the file
- Paste the file into the CSV and JSON converter with 'CSV to JSON' selected and read the row number in the error.
- Open the file in a text editor and go to that row (the header row is row 1).
- Inside the quoted cell, double every quote that belongs to the text itself, and leave the opening and closing quotes as they are.
- Paste the corrected file and check that the output appears.
A different message: a field that never closes
If a field opens with a quote and no closing quote exists anywhere, as in TV,"55 screen, the message is different: 'a field starts with a quote that is never closed'. That usually means the file was cut off while copying, or the closing quote was deleted by mistake. The fix is to add the closing quote in the right place, which the tool cannot guess for you.
Why the tool does not repair it automatically
Because a guess can merge two cells or two rows into one value without you noticing, and wrong data then flows into your store or system. Stopping with a row number is a little slower, but it guarantees every value in the output is what you actually wrote. To avoid the problem in the first place, export the file from a spreadsheet program instead of typing it, since those programs double the quotes themselves.
Common questions
Should I replace the inch mark with the word 'inch'?
You can, but you do not have to. Doubling it inside a quoted field keeps the mark as it is.
Does the doubled quote show up in the JSON?
No. In JSON it appears as a single quote preceded by a backslash, which is its normal form in JSON.
Is the row number the line number in my editor?
Not always. If the file has cells with line breaks inside, the two numbers can differ.
