The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration
用过Mysql的人都知道,这个时区问题真个磨人的小妖精,哪天一忘记设置了就会出来磨磨你!!!
之前用的解决方法都是在Mysql的配置上添加与时区相关的配置,但是今天看到一篇博客:https://blog.csdn.net/qq_37630354/article/details/82814330
我觉得这可能是个“一劳永逸”的解决办法,便稍作记录
在你的Mysql安装目录下找到一个 my.in的配置文件,然后用notepad++打开它(或者其他的工具)

然后添加以下这句
default-time-zone='+08:00'

保存后重启Mysql,忘了Mysql相关操作命令的可以看这里
重启成功后登陆Mysql并执行这一句: show variables like '%time_zone%';
忘了Window下怎么登陆MySQL的可以点这里
修改成功的话会看到如下的提示

如果没看到的话可能是修改配置文件出错了,或者是没重启成功1
The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration的更多相关文章
- 解决mysql时区与系统时区不一致问题。异常:The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.
异常信息:The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone ...
- SpringBoot报错:The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone
解决方法: 在数据库连接url配置后边加&serverTimezone=GMT%2B8 例: jdbc:mysql://127.0.0.1:3306/test改为jdbc:mysql://12 ...
- The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.
今天用mysql连接数据库时,出现The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than o ...
- MySql数据库时区异常,java.sql.SQLException: The server time zone value '?й???׼ʱ?' is unrecognized or represents more than one time zone.
JDBC访问MySql异常 Exception in thread "main" org.apache.ibatis.exceptions.PersistenceException ...
- 【JDBC】java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.
在使用阿里的druid 时,报了一个异常java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized ...
- 异常: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configurat
异常: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. ...
- JDBC告警系列(一)The server time zone value 'ÖÐ' is unrecognized or represents more than one time zone.
一.现象 java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents ...
- 解决java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone
使用spring boot整合MySQL时一直报 java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecog ...
- 【问题解决:时区】连接MySQL时错误The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone
问题描述: MySQL升级到8.0.11之后连接数据库报错: Your login attempt was not successful, try again. Reason: Could not g ...
- 解决The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone
Spring Boot JPA 使用Mysql是出现如下错误: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represe ...
随机推荐
- iOS 控制器的生命周期(UIController)
前言: 在iOS开发中,控制器的生命周期非常重要,什么时候加载页面,什么时候请求接口,什么时候刷新界面等等,都有很多值得优化的地方 loadView: 最先执行的方法,控制器关联的有Nib文件的时候, ...
- 资讯类产品-创业邦APP产品原型模板公开分享
众所周知,知识付费和资讯是近年来两个受关注度极高的互联网产品方向.18年喜马拉雅“123狂欢节”,3天时间内容消费额4.35亿,足见知识付费内容市场的火爆.字节跳动凭借今日头条APP起家,逐渐跻身互联 ...
- OI养老专题01:约瑟夫问题
有M个人,其编号分别为1-M.这M个人按顺序排成一个圈.现在给定一个数N,从第一个人开始依次报数,数到N的人出列,然后又从下一个人开始又从1开始依次报数,数到N的人又出列...如此循环,直到最后一个人 ...
- Java基础之数组详解
数组对于每一门编程语言来说都是重要的数据结构之一,当然不同语言对数组的实现及处理也不尽相同. Java 语言中提供的数组是用来存储固定大小的同类型元素. 你可以声明一个数组变量,如 numbers[1 ...
- 002-MVC布局页
~/Views/Shared/_LayoutPage1.cshtml <!DOCTYPE html> <html> <head> <meta name=&qu ...
- 虚拟机——虚拟机VMware Workstation 的.vmdk格式与VirtualBox 的.vdi格式相互转换
啦啦啦~~~ 由于现在Vmware Workstation的越来越普及,让很多小伙伴不知道怎么把以前用的VirtualBox虚拟机vdi格式转换成vmdk格式,下面我们就来转换一下吧... 第一步:找 ...
- Emmet:HTML/CSS代码快速编写神器教程
Emmet的前身是大名鼎鼎的Zen coding,如果你从事Web前端开发的话,对该插件一定不会陌生.它使用仿CSS选择器的语法来生成代码,大大提高了HTML/CSS代码编写的速度,比如下面的演示: ...
- DP题目推荐合集(洛谷/UVa)
今天下午要参加海淀区的比赛了...这几天临时抱佛脚刷了几道DP,正所谓临阵磨枪,不快也光...下面我 就把最近刷到的,自己觉得不错的动态规划题列出来: 1.P2690 接苹果 :(基础二维DP) 2. ...
- Color Schema 配色随笔
附pdf文件: ColorSchema.pdf
- Oarcle之事务
update:更新 例如转账: update emp_ temp set sal = sal-500 where ename = 'JONES':(更新表中sal项 为sal-500 是当ename= ...