I am trying to load timezones into my MySql instance (which runs on Unbuntu) so that I can use the CONVERT_TZ function, but when I run the following command:
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql
I get the following output, and when I try to use CONVERT_TZ , it just returns NULL :
Warning: it is not possible to load '/ usr / share / zoneinfo / Asia / Riyadh87' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / Asia / Riyadh88' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / Asia / Riyadh89' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / Mideast / Riyadh87' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / Mideast / Riyadh88' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / Mideast / Riyadh89' as a time zone. Skip it. Warning: it is not possible to load '/usr/share/zoneinfo/iso3166.tab' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Asia / Riyadh87' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Asia / Riyadh88' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Asia / Riyadh89' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Mideast / Riyadh87' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Mideast / Riyadh88' as a time zone. Skipping This. Warning: it is not possible to load '/ usr / share / zoneinfo / posix / Mideast / Riyadh89' as a time zone. Skipping This. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Asia / Riyadh87' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Asia / Riyadh88' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Asia / Riyadh89' as a time zone. Skip it. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Mideast / Riyadh87' as a time zone. Skipping This. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Mideast / Riyadh88' as a time zone. Skipping This. Warning: it is not possible to load '/ usr / share / zoneinfo / right / Mideast / Riyadh89' as a time zone. Skipping This. Warning: it is not possible to load '/usr/share/zoneinfo/zone.tab' as a time zone. Skip it.
Does anyone have an idea why this is happening?
PS:
I use the following method to convert datetimes:
CONVERT_TZ(NOW(),'UTC', 'PCT')
Is it possible that I'm just converting incorrectly and this is causing the NULL results?
database mysql
Abe Miessler Aug 13 '13 at 18:10 2013-08-13 18:10
source share