Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

数据库新建和更新时间差13个小时,请问怎么修正这个时间 #4973

Closed
jacknotes opened this issue Sep 15, 2023 · 3 comments
Closed
Labels

Comments

@jacknotes
Copy link

数据库新建和更新时间差13个小时,请问怎么修正这个时间
image

@dosubot
Copy link

dosubot bot commented Sep 15, 2023

🤖

对不起,我无法查看您提供的图片链接。关于您的问题,如果您在使用MySQL数据库时遇到创建和更新时间相差13小时的问题,这可能是由于MySQL服务器和应用服务器之间的时区设置不一致导致的。

您可以尝试以下方法来解决这个问题:

  1. 检查并确保您的MySQL服务器和应用服务器的系统时区设置是一致的。您可以通过在MySQL命令行中运行SELECT @@global.time_zone, @@session.time_zone;来查看MySQL的时区设置。

  2. 如果时区设置不一致,您可以在MySQL服务器上设置全局时区,例如SET GLOBAL time_zone = '+8:00';,这将全局时区设置为东八区。

  3. 在您的应用程序中,您也可以在每个MySQL连接的会话级别设置时区,例如SET time_zone = '+8:00';

请注意,更改时区设置可能需要MySQL的系统权限,如果您没有这些权限,您可能需要联系您的数据库管理员。

如果以上方法不能解决您的问题,或者您需要更多的帮助,能否提供更多的信息,例如您的服务器环境、Apollo的配置以及您在哪里看到这个时间差的问题?这将有助于我更好地理解和解决您的问题。

Sources


This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

If you want to continue the conversation, start your reply with @dosu-bot.

@stale
Copy link

stale bot commented Oct 15, 2023

This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Oct 15, 2023
@stale
Copy link

stale bot commented Oct 28, 2023

This issue has been automatically closed because it has not had activity in the last 7 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions.

@stale stale bot closed this as completed Oct 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant