数据库5和数据库8的区别:
mysql数据库的URL:
mysql8.0 : "jdbc:mysql://localhost:3306/demo?useSSL=false&serverTimezone=Asia/Shanghai&autoReconnect=true";
Url="jdbc:mysql://localhost:3306/test?useSSL=false&serverTimezone=Asia/Shanghai&characterEncoding=utf-8&autoReconnect=true";
参考于:https://www.cnblogs.com/han-1034683568/p/9534681.html
mysql5.x: “jdbc:mysql://localhost:3306/demo”
用户名:USERNAME: root
密码: root
加载具体的驱动类:
mysql8.0: Class.forName("com.mysql.cj.jdbc.Driver");
mysql5.x: Class.forName("com.mysql.jdbc.Driver");
数据库5和护具库8的区别