Bug #97834 Workbench Data Import broken due to import file path escaping
Submitted: 29 Nov 2019 20:09 Modified: 30 Nov 2019 4:57
Reporter: Laurents Meyer (OCA) Email Updates:
Status: Verified Impact on me:
Category:MySQL Workbench: Administration Severity:S2 (Serious)
Version:8.0.18 OS:Windows
Assigned to: CPU Architecture:Any

[29 Nov 2019 20:09] Laurents Meyer
The data import is not working anymore, probably due to escaping the import file paths backslashes as double backslashes:

20:50:21 Restoring mydatabase (mytable)
Running: "C:\Program Files\MySQL\MySQL Server 8.0\bin\mysql.exe" --defaults-file="c:\users\username\appdata\local\temp\tmpnlwk9p.cnf"  --protocol=tcp --host=localhost --user=root --port=3306 --default-character-set=utf8 --comments --database=mydatabase < "C:\\Databases\\MySQL\\MySQL Server 8.0\\Dumps\\Dump20191129\\mydatabase_mytable.sql"
Operation failed with exitcode None

As a workaround, you have to run the import manually from the command line/PowerShell, which works (as long as no double backslashes are being used).

How to repeat:
Run an import with a previously backuped database (either SQL file or directory).

Suggested fix:
The restore functionality should work again. This can probably accomplished by using a single backslash for the import file path (or all import file paths in case an import directory is used instead of a single file).
[29 Nov 2019 20:12] Laurents Meyer
This is still in issue in 8.0.18. It was already not working in 8.0.17.
[29 Nov 2019 20:17] Laurents Meyer
And while you at it, the "Default Target Schema" combo box is misaligned, as it the "Import from Self-Contained file" radio button.

When you fixing it, please also fix the #96199 bug, so we don't have to use tab and enter blindly on notebooks with a display height of only 768 pixels.
[30 Nov 2019 4:57] MySQL Verification Team
Hello Laurents,

Thank you for the report and feedback.
Verified as described on Win 10 and WB 8.0.18 (with custom path to mysql.exe{which has SPACE in the path} instead of using bundled version).