How to disable column-statistics in MySQL 8 permanently? How to disable column-statistics in MySQL 8 permanently? mysql mysql

How to disable column-statistics in MySQL 8 permanently?


Workaround for me:

  1. Create file named mysqldump.cmd with contents:
    @echo off    "c:\Program Files\MySQL\MySQL Workbench 8.0 CE\mysqldump.exe" %* --column-statistics=0

(replace path to mysqldump.exe if necessary)

  1. Open MySQL Workbench and go to Edit > Preferences > Administration, change path to mysqldump tool and point it to mysqldump.cmd


Easiest Work Around

When using Mysql Workbench 8.0

  • Open the "Data Export" Tab
  • Click Advanced Options enter image description here
  • Under the Other heading, set column statistics to 0 enter image description here
  • Export againenter image description here

Best of luck!


The idea is this: each server version has a dedicated mysqldump version. Not ideal and certainly not very backwards compatible, but that's the situation. MySQL Workbench can only include one mysqldump binary, so the latest one is used. The approach to download the MySQL 5.7 zip and use mysqldump from there is a good workaround without many side effects. You only have to be careful which server you dump with which dump version.

If you like to have that column stat flag automatically applied by MySQL Workbench please file a bug report at https://bugs.mysql.com.

Update

Meanwhile a bug report has been created for this issue: https://bugs.mysql.com/bug.php?id=91640