mysql database date type time taken more than 8 hours

Database time is as follows:

 

 Database Configuration

the Spring: 
the DataSource:
username: root
password: root
url: jdbc: MySQL: // localhost: 3306 / ag_admin & serverTimezone = UTC & useUnicode = to true & characterEncoding = UTF8 & useSSL = false?
Driver-class-name: com.mysql.jdbc.Driver

check out the following data : j more than 8 hours

 

 

Because of the time most of the reason we use the default time zone is the East eight districts, and database configuration serverTimezone = UTC is Coordinated Universal Time (US time), so the difference between the eight hours.

solution:

Time zone changed to the East eight districts

serverTimezone= GMT%2B8

 

Guess you like

Origin www.cnblogs.com/lfyu/p/12523222.html