Confusion regarding double quote in CSV file

""Ford" 1997" 

      

Will this be considered a valid field in the CSV file? Let's say the entire entry:

""Ford" 1997",E350,"Luxurious car"

      

Or maybe:

""Ford",1997,"Luxurious car"

      

Will this be a valid entry?

+3


source to share


1 answer


Um. I'm sure there is no standard for csv. I think it's crap to say what is really what is not. It depends a lot on where the data is going (regardless of the standard). If excel accepts this, and it does, then great. If some other goal does not accept it - so it is.

However, what you are dealing with is a comma separated value.



If we look at the comma, your entry is fine (but there is a possibility of a data type error). If we look at quotes nested in comma-separated fields - your records are bad.

0


source







All Articles