我需要mysql_tzinfo_to_sql
为一个项目运行该实用程序,并且每当我尝试运行第一个命令时:
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql
我收到以下错误:
ERROR 1105 (HY000) at line 46426: ORDER BY ignored as there is a user-defined clustered index in the table 'time_zone_transition'
我的理解是因为ORDER BY
没有处理它不会进一步更新时区,虽然我从未接触过这个基础,但我不确定如何最好地解决这个问题。
同样在尝试运行时:
mysql_tzinfo_to_sql tz_file tz_name | mysql -u root -p mysql
我收到以下错误:
mysql_tzinfo_to_sql: Can't create/write to file 'tz_file' (Errcode: 2 "No such file or directory")
Problems with zoneinfo file 'tz_file'
编辑:我在 macOS Sierra (10.12.6) 上运行,因此我试图做所有这些:https ://docs.djangoproject.com/en/1.10/ref/databases/#mysql-time-zone -定义