01S00 Invalid connection string feature SQLException: The server time zone value '�й���׼ʱ��' is unrecognized

SQLException: The server time zone value '�й���׼ʱ��' is unrecognized


When configuring datasource.url, you cannot simply configure it like this:

spring.datasource.url=jdbc:mysql://localhost:3306/chat
  • 1

You need to add some necessary suffix information (you can change it to the following configuration):

spring.datasource.url=jdbc:mysql://localhost:3306/chat?useUnicode=true&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=UTC

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324931206&siteId=291194637