位置: 编程技术 - 正文

Windows下安装MySQL 5.7.17压缩版中遇到的坑(windows下安装nas)

编辑:rootadmin

推荐整理分享Windows下安装MySQL 5.7.17压缩版中遇到的坑(windows下安装nas),希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:windows下安装mysql8.0,windows 安装 mysql,windows下安装mysql5.7,windows下安装mysql的命令,windows下安装mysql5.7 ini配置,windows下安装mysql5.7 ini配置,windows下安装mysql5.7 ini配置,windows下安装mysql的命令,内容如对您有帮助,希望把文章链接给更多的朋友!

首先下载最新的MySQL 5.7. Community 压缩版 for Windows -bit:

官方下载地址: you installed MySQL using the Noinstall package, you may need to initialize the data directory:

Windows distributions prior to MySQL 5.7.7 include a data directory with a set of preinitialized accounts in the mysql database. As of 5.7.7, Windows installation operations performed using the Noinstall package do not include a data directory. To initialize the data directory, use the instructions at Section 2..1.1, “Initializing the Data Directory Manually Using mysqld”.

具体可参考这两个链接:

2.3.5.4 Initializing the Data Directory

2..1.1 Initializing the Data Directory Manually Using mysqld

原因找到了,那我们来手动Initialize Data Directory一下啊:

然后依次:

熟悉的mysql>应该就出来了。

希望对遇到类似坑的人有所帮助,究其原因就是5.7.7及以后的压缩包版本,更改为需要手动Initialize Data Directory了。

技无一招鲜,坑要一路填。

我的环境:

Windows -bit MySQL Community Server 5.7. for Windows (x, -bit), ZIP Archive

(分割线,以上MySQL 5.7.就算安装完毕了。)

最后手贱,搞个SQLAlchemy测试MySQL:

Windows下安装MySQL 5.7.17压缩版中遇到的坑(windows下安装nas)

结果发现输出结果的同时有个报警:

Warning: (, "Incorrect string value: 'xD6xD0xB9xFAxB1xEA...' for column 'VARIABLE_VALUE' at row ")

这是怎么回事呢?要说各种字符集设置都检查n次,应该没啥问题了......

无数次思考、试验中,发现了啥?发现了啥?发现只要show variables like '%charac%';一下,就会出来一个告警!

再来看看这个这个Warning:

不正是它吗?MySQL的Bug莫不是?!OMG!

好吧!重回MySQL 5.6.!

告警不见了!

接着重新建库、建表,测试程序:

这下OK了,最终还是兜了一圈回到了MySQL 5.6.。

安静地写Python,没人吵,也不像前端撕来撕去的——岁月静好、Python静好。

最后赞一下Visual Studio Code:

总结

本文链接地址:https://www.jiuchutong.com/biancheng/350032.html 转载请保留说明!

上一篇:CentOS 7下使用RPM安装mysql5.7.13(centos中rpm包怎么安装)

下一篇:mysql 5.7.17 免安装版配置方法图文教程(windows10)(mysql免安装版下载)

免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

鄂ICP备2023003026号

网站地图: 企业信息 工商信息 财税知识 网络常识 编程技术

友情链接: 武汉网站建设 电脑维修 湖南楚通运网络