Database error on first login

Ask your questions regarding TimeTrex installation here.
Locked
davidstrauss
Posts: 4
Joined: Wed Sep 20, 2006 10:15 am

Database error on first login

Post by davidstrauss »

Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysqlt error: [1298: Unknown or incorrect time zone: ''] in EXECUTE("SET SESS in /var/www/vhosts/fourkitchens.com/subdomains/time/httpdocs/classes/adodb/adodb-exceptions.inc.php on line 78

We're running "TimeTrex v1.2.0-beta2" with "MySQL 4.1.20-log"
mikeb
Posts: 709
Joined: Thu Jul 27, 2006 11:58 am

Re: Database error on first login

Post by mikeb »

davidstrauss wrote:Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysqlt error: [1298: Unknown or incorrect time zone: ''] in EXECUTE("SET SESS in /var/www/vhosts/fourkitchens.com/subdomains/time/httpdocs/classes/adodb/adodb-exceptions.inc.php on line 78

We're running "TimeTrex v1.2.0-beta2" with "MySQL 4.1.20-log"
Try changing line 56 of includes/Interface.inc.php to:

if ( $db->dataProvider == 'mysql' AND $current_user_prefs->getTimeZone() != '' ) {

See if that fixes the issue. If not, you may need to load the proper timezones in to MySQL by running:

mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql

Or following the instructions from:
http://dev.mysql.com/doc/refman/4.1/en/ ... pport.html

Please let me know which one of these fixes the problem so I can work around it in future versions of TimeTrex.

Thanks.
TimeTrex Community Edition is developed and supported by volunteers.
Help motivate us to continue by showing your appreciation!
davidstrauss
Posts: 4
Joined: Wed Sep 20, 2006 10:15 am

Post by davidstrauss »

Did you mean line 76?

"if ( $db->dataProvider == 'mysql' ) {"
davidstrauss
Posts: 4
Joined: Wed Sep 20, 2006 10:15 am

Post by davidstrauss »

With that fix (line 76), I can set my preferences, but then I get:

Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysqlt error: [1298: Unknown or incorrect time zone: 'US/Central'] in EXECUTE in /var/www/vhosts/fourkitchens.com/subdomains/time/httpdocs/classes/adodb/adodb-exceptions.inc.php on line 78
davidstrauss
Posts: 4
Joined: Wed Sep 20, 2006 10:15 am

Post by davidstrauss »

Okay. I got it working with the fix combined with loading time zone data into MySQL.
mikeb
Posts: 709
Joined: Thu Jul 27, 2006 11:58 am

Post by mikeb »

davidstrauss wrote:Okay. I got it working with the fix combined with loading time zone data into MySQL.
Okay, thanks. I guess relying on the fact that MySQL has timezone data out of the box is a bad thing. I will add this to our TODO list to fix in future versions.
TimeTrex Community Edition is developed and supported by volunteers.
Help motivate us to continue by showing your appreciation!
Locked