Bug #89044 Import Wizard does not import entire file
Submitted: 23 Dec 2017 15:39 Modified: 27 Jun 2019 7:04
Reporter: Mike Lawrence Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:6.3.10 OS:Windows (Microsoft Windows 10 Enterprise)
Assigned to: Assigned Account CPU Architecture:Any
Tags: WBBugReporter

[23 Dec 2017 15:39] Mike Lawrence
Description:
I have had numerous issues with importing csv files into MySQL using the Workbench Import Wizard where there is no error given and only the first so many records are imported and the rest I have to run a second import and append.

For example: I have a 234 record file, including the header, and only the first 170 rows are imported, so I have to save a second copy of the file with the other 64 records + header and run a second import.

How to repeat:
Import a CSV file with 200+ records using Import Wizard

Suggested fix:
Import the entire file and generate errors when the entire file is not imported
[23 Dec 2017 21:13] MySQL Verification Team
Thank you for the bug report. Please try 6.3.10 version, if the issue continues please provide a *.cvs file and it`s create table statement and indicating the numbers of rows expected to import.
[24 Jan 2018 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[5 Mar 2018 18:30] Mike Lawrence
Problem still occurs with 6.3.10, but found the problem seems to be related to the character set, as the table is defined with UTF8 I was importing with UTF8, but found when I changed to Latin1 the import imported all of the data.
[12 Mar 2018 23:23] MySQL Verification Team
Please provide the create table statement too. Thanks.
[14 Mar 2018 2:58] Mike Lawrence
Here is the requested table create

CREATE TABLE `trans_apps` (
  `origAppCode` varchar(96) COLLATE utf8_unicode_ci NOT NULL,
  `appCode` varchar(32) COLLATE utf8_unicode_ci NOT NULL,
  `appName` varchar(64) COLLATE utf8_unicode_ci NOT NULL,
  `appCategory` varchar(64) COLLATE utf8_unicode_ci NOT NULL,
  PRIMARY KEY (`origAppCode`)
[14 Mar 2018 8:29] Chiranjeevi Battula
Hello Mike,

Thank you for the feedback.
As per your ".cvs" having only 112 and those are imported at a time using with MySQL workbench 6.3.10 version.
Could you please provide repeatable steps (exact steps, more records of ".cvs" file etc. - please make it as private if you prefer) to confirm this issue at our end?

Thanks,
Chiranjeevi.
[14 Mar 2018 8:31] Chiranjeevi Battula
Screenshot

Attachment: Bug_89044.PNG (image/png, text), 103.22 KiB.

[15 Apr 2018 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[16 May 2019 13:52] Vince Osisek
Am experiencing same issue - only 73 records import (out of 766), when using the Table Import Wizard, and no errors shown or logged.  Is this fixed ?
[4 Jun 2019 1:03] David Polo
Hi, I am having the same issue with MySQL Workbench version 8.0.15, I tried to import 1123 rows from a CSV file and the Table Wizard Import only imports 1036 rows.
[4 Jun 2019 17:02] Mike Lawrence
I found that changing the encoding to UTF-8 solved my import problem
[27 Jun 2019 7:04] MySQL Verification Team
Hi Vince, David,

Does changing the encoding to UTF-8 resolves your issue? I could not reproduce with the existing .csv file. Could you please provide exact import file and table structure to reproduce this issue at our end? But before that please give it a try on WB 8.0.16 as we don't fix bugs in old versions, don't backport bug fixes, so need to check with latest version anyway. So, please, upgrade and inform us if problem still exists.

regards,
Umesh
[28 Sep 2020 14:48] Edward Crichton
I've just experienced this with 8.0.19 on Windows 10.

The import stopped at a particular point before all rows were processed. No error message in the log. It stops with success.

I tried to import the rest by removing the rows that had been imported already, but it reports: Can't analyze file. Please try to change encoding type. If that doesn't help, maybe the file is not: csv, or the file is emtpy.

The file is a non-empty csv saved from Excel.

Two rows down from the row where it stopped is the character ' ’ ' which is U+2019 UTF-8 E2 80 99 "RIGHT SINGLE QUOTATION MARK". However, Excel has decided to encode it as x92 from CP1252.

With the Encoding set to UTF-8, if I remove that character, it works. If I add that character somewhere it fails. If I change the Encoding drop down to cp1250 it works.

That would be this: http://effbot.org/zone/unicode-gremlins.htm

So the csv can start to import as UTF-8 until it hits a non-valid UTF-8 character in the stream and then it stops without giving an indication as to why that might be.