MySQL Forums
Forum List  »  Newbie

Re: CSV to MySQL 8 issues
Posted by: Peter Brawley
Date: October 24, 2018 09:24AM

> What do you need? A CSV file and a table structure? And how do I send attachments?

What's needed to reproduce the problem you reported: Create Table cmd, csv file, Load Data cmd.

> Colorno is a STRING or 5 characters width which contains numerals ('2', '22', '345', etc. )

?! Defined in the table as an int, whence your error "ERROR 1366 (HY000) Incorrect integer value: '\FEFF1' for column 'Colorno' at row 1".

Quote

Loading a string function to varchar(24) example. With 5.7 if the string value was, say, 30 characters. Loading into varchar(24) field it would just chop enough characters from the end to make it fit varchar(24). Now it errors. Is there any setting that can make it like 5.7?

Sql_mode and whether the Load Data uses LOCAL both affect error/warning behaviour, see https://dev.mysql.com/doc/refman/8.0/en/load-data.html. I'm unaware of 5.7-8.0 differences.

Options: ReplyQuote


Subject
Written By
Posted
October 23, 2018 08:28AM
October 23, 2018 10:24AM
October 23, 2018 10:57AM
October 23, 2018 12:02PM
Re: CSV to MySQL 8 issues
October 24, 2018 09:24AM
October 24, 2018 11:24AM
October 24, 2018 11:57AM
October 24, 2018 04:46PM
October 24, 2018 08:10PM
October 25, 2018 02:23PM
October 25, 2018 03:44PM
October 25, 2018 08:53PM
October 25, 2018 10:01PM
October 26, 2018 06:56AM
October 26, 2018 09:53AM
October 26, 2018 10:19AM
October 26, 2018 10:49AM
October 26, 2018 11:27AM
October 27, 2018 08:41PM
October 28, 2018 12:58PM
October 29, 2018 11:41AM
October 29, 2018 12:23PM
October 29, 2018 07:53PM
October 23, 2018 10:27AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.