Forum Discussion

thetestersqa's avatar
thetestersqa
New Member
21 days ago

Uploading CSV file throws an error

Hi, I'm new here and currently using Zephyr Scale as our test management tool. I have a question about uploading CSV files. Every time I try to upload a file, I get an error. I even tried uploading a file I downloaded from Zephyr to ensure the format wasn't the issue and it is still throwing the same error message.

 

1 Reply

  • MisterB's avatar
    MisterB
    Icon for Champion Level 3 rankChampion Level 3

    Hi,

    I can try to help.  If you haven't seen the relevant Zephyr Help page you can read that here

    To verify that a 'good' file does import I would try importing a 1 record CSV file for the least amount of fields needed, so all you need is 1 column of data which you would map to the Name column.  That really should work and prove that everything works as it should.

    From there, I would add 1 row of your import file with all the fields you are importing, and see if that works.  If it does, expand until you hit the error.  When you hit the error check your data content - or you could do this first - and look for carriage returns, other delimiters just general weirdness.  It'll be something like that.  Opening the CSV file in Notepad or another basic text editor with word wrap disabled might be easier.  When viewed like this you can scroll left<>right and it becomes pretty obvious when a row of data looks different to the others.

    Here's some info I found on problematic characters when parsing CSV data:

    Problematic Character / IssueWhy It Causes IssuesHow to Fix It
    Comma (,)Treated as a column separator; unescaped commas split fields incorrectly.Enclose affected fields in double quotes ("like, this").
    Double Quote (")Used to wrap text fields; unescaped quotes confuse parsers.Escape with another quote ("He said ""hi""").
    Newlines (\n, \r\n)Treated as a new row even inside a field.Wrap the field in double quotes ("Line 1\nLine 2").
    Delimiter CollisionsCustom delimiters (e.g., ;, `, \t`) can appear in text and break parsing.
    Unescaped / Inconsistent QuotesMismatched or malformed quotes throw off the parser.Ensure consistent quoting and escape double quotes properly.
    Null Bytes / Control CharactersParsers may reject or crash when encountering binary or control characters.Sanitize the data—remove or encode problematic characters before writing the CSV.
    Encoding IssuesWrong encoding (e.g., not UTF-8) can corrupt non-ASCII characters.Use UTF-8 encoding (optionally with BOM) when exporting the file.
    Extra / Missing ColumnsParsing breaks if line structure is inconsistent, often due to the issues above.Identify and fix malformed rows with unexpected column counts.