![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
mysql
Jerry_1998
这个作者很懒,什么都没留下…
展开
-
mysql对包含数字的字符串进行查询排序(对,就是你想的那种)
问题先来看一下数据库存储的数据共六条测试数据,code列的值分别是测试10、测试2、测试12、测试1、测试11、测试3现在想得到如下图的查询结果即查询到的顺序是测试1、测试2、测试3、测试10、测试11、测试12解决方案先来看一下最先想到的sqlSELECT * FROM park_test ORDER BY `code` asc得到的结果是很明显和我们预想的不一样,为什么呢?就是当mysql字段类型是字符串类型时,在默认情况下使用order by 字段名称 desc/asc 进原创 2020-09-16 17:36:25 · 1401 阅读 · 0 评论 -
Windows系统 Mysql8.0.11:数据库主从同步配置
Windows Mysql8:数据库主从同步配置参考文章:https://blog.csdn.net/imHanweihu/article/details/89419129本地运行两个mysql服务,请参考:Windows系统 Mysql8.0.11:同ip运行两个mysql服务1、确保两个mysql服务同时运行2、使用mysql连接上两个mysql服务3、在主库敲命令查看主库状态...原创 2019-07-31 16:00:25 · 2190 阅读 · 1 评论 -
Windows系统 Mysql8.0.11:同ip运行两个mysql服务
Windows系统 Mysql8.0.11:同ip运行两个mysql服务参考文章:https://blog.csdn.net/imHanweihu/article/details/894041651、背景需要做数据库的读写分离以及主从同步,所以需要运行两个mysql服务。windows系统为windows 10 专业版,mysql为mysql-8.0.11-winx64,下载地址:htt...原创 2019-07-31 16:00:54 · 901 阅读 · 0 评论 -
SpringBoot整合Druid报错解决:The server time zone value '�й���ʱ��' is unrecognized or represents.........
1、SpringBoot 整合Druid参考文章:Druid(新版starter)在SpringBoot下的使用2、报错解决2.1、报错信息The server time zone value ‘�й���ʱ��’ is unrecognized or represents more than one time zone. You must configure either the s...原创 2019-08-24 14:32:49 · 2937 阅读 · 0 评论