MySQL error 1064 syntax but everything seems fine

人盡茶涼 提交于 2019-11-29 06:57:33

Problem is the word VISIBLE, remove it and it will work. Index are visible by default.

Your question: "If i remove VISIBLE it works just fine, so why did mysql workbench decided to add visible?"

My answer: The option to mark index invisible is not yet implemented in MariaDB (afaik!).

Update:

The syntax for MariaDB is different, please see this reference: https://jira.mariadb.org/browse/MDEV-7317

Just to add to those who are using Maria DB with MySQL Workbench, you don't need to install mysql. You can just change 'Default Target MySQL Version' from Preferences to 5.7 or 5.6, and the VISIBLE keyword will be removed by workbench.

Here is a link from mysql bugs https://bugs.mysql.com/bug.php?id=92269

I am using MySQL Workbench and have same problem. Change in the Preferences but it did not work.

Solution: If you export forward-engineer the model you need to change the configuration on another place.

  1. Go to Model > Model Options
  2. Inside the Model Options, go to MySQL
  3. Then change the "Target MySQL Version" to 5.6

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!