I would also like to point out, as an aside, that Spain doesn't actually have two
timezones - it has a single timezone with daylight savings time. The real question is,
thus, to figure out wether or not you are on DST or not.
That, however, I have no idea how to do - the system takes care of it automagically. I'm
not even sure it gets tracked somewhere on the system, you might need to download and
parse the rules yourself in your code.
Unless, of course, you're talking about the timezone difference between Spain and the
Canaries, but you mentioned summer/winter time explicitly, so I don't think so.
----- Original Message -----
> From: "John Daisley" <daisleyjohn@stripped>
> To: "Rocio Gomez Escribano" <r.gomez@stripped>
> Cc: mysql@stripped
> Sent: Friday, 3 June, 2011 12:08:34 PM
> Subject: Re: timezone
> now() returns the current system time which doesn't really have a
> great deal to do with time zones.
> You can check what the current time zone is set to with the following
> show variables like 'time_zone';
> but that is likely to return the value ' SYSTEM ' which means it
> takes the value from the host operating system ( usually set in
> /etc/timezone ).
> You can set the time_zone variable either globally or per session to
> an offset of UTC as follows
> SET time_zone='+00:00:00';
> SET GLOBAL time_zone='+00:00:00';
> Or you can specify a ' default_time_zone ' in your my.cnf/my.ini
> options file.
> You can also set the time_zone variables to a named offset which will
> then take account of daylight savings times but to do this you must
> first load the mysql time zone tables.
> I strongly suggest you read the manual section relating to time zone
> support which you can find here
> On 3 June 2011 10:27, Rocio Gomez Escribano <
> r.gomez@stripped > wrote:
Bier met grenadyn
Is als mosterd by den wyn
Sy die't drinkt, is eene kwezel
Hy die't drinkt, is ras een ezel