After enabling the event module for the first time I got the following errors:

# user warning: Incorrect datetime value: '-10:00:00' for column 'offset' at row 1 query: INSERT INTO event_timezones (timezone, name, offset, offset_dst, dst_region) VALUES (37, 'America/Adak', '-10:00:00', '-9:00:00', 15) in C:\Development\Projects\NSHP-600\sites\all\modules\event\event.install on line 116.
# user warning: Incorrect datetime value: '-9:00:00' for column 'offset' at row 1 query: INSERT INTO event_timezones (timezone, name, offset, offset_dst, dst_region) VALUES (38, 'America/Anchorage', '-9:00:00', '-8:00:00', 15) in C:\Development\Projects\NSHP-600\sites\all\modules\event\event.install on line 116.
# user warning: Incorrect datetime value: '-4:00:00' for column 'offset' at row 1 query: INSERT INTO event_timezones (timezone, name, offset, offset_dst, dst_region) VALUES (39, 'America/Anguilla', '-4:00:00', '-4:00:00', 0) in C:\Development\Projects\NSHP-600\sites\all\modules\event\event.install on line 116.
.
.
.

It seems (at least with my current configuration) MySQL can not handle negative values for date-time columns therefore all the insert statements with negative values failed. I'm running Drupal 6 RC2, PHP 5.0, Mysql 5.0 and Apache 2.0 on windows XP.

Just for sake of curiosity, is there any particular reason why the columns were changed from a INT data type to date-time? (even when drupal core tables use INT columns to store date-time information)

Comments

erikwebb’s picture

This is related to the issue I am having #227501: System time setting isn't right when Event 6.x active.

killes@www.drop.org’s picture

Status: Active » Closed (duplicate)

The reason is that datetime is the proper sql type for storing date and time info.

Marking a duplicate of the referenced issue.