Mysql – How to get line that causes error when loading from csv to MySQL

csvencodingerrorsimportMySQL

I'm trying to load data from CSV file, but occurs error

Error Code: 1366. Incorrect integer value: 'abcdxxx' for column 'col' at row 123545.

I Have file with multiple breaklines CRLF's in content, the line separator is LF, text tools cannot find returned string, so I suppose there is problem with charset. Do exists posibility to have returned values(line) from file that caused error server returned? I cannot find values that caused error.

Best Answer

Errors occured because of unescaped backshlashes. Values preceeded with \ were inrepereted as ascii signs, but they weren't. To avoid this error backslash - \ should be escaped by additional backslash - \ so occurences of backslashes should be changed to double backslashes - \\ .