Set Mysql Timezone Failed, Need Help!!


I get problem again when I try to sett mysql timezone:

here is my code:

Yii::app()->getDb()->createCommand("SET time_zone='Europe/Helsinki'")->execute();

the error is:

CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 1298 Unknown or incorrect time zone: 'Europe/Helsinki'SET time_zone='Europe/Helsinki'

I have try to change timezone value become ‘Asia/Jakarta’ or more I use this time zone(

but still error like above.

maybe some one can point me how to fix this.

Thank you very much for everything



It’s database instalation dependant… if you are using MySql try to run this command from phpMyAdmin for example to see the result…

Take a look here for the MySql documentation about timezone:…ne-support.html

it says: Named time zones can be used only if the time zone information tables in the mysql database have been created and populated.

oh it need database! ok sir it useful information :D he…he… thanks