Re: This day last year page
Posted: Mon 02 Jul 2012 10:55 pm
I think I have discovered a slight problem caused by where I host my website.
When I have started to run specific SQL queries, I noticed that incorrect data was being returned at certain times.
I have narrowed this down to the fact that Glovine host my website and they are 10 hours ahead of me in the UK.
So, when I run a query at say 11.00am UK time for Max temp for this day last year, the figure is correct, but if I run the same query at 8.00pm UK time, data is returned for "tomorrow last year".
Investigating this more, it is clearly to do with the time of the MySQL server, but I don't appear to be able to change this through the Glovine control panel.
I've tried several different methods of setting the timezone in my PHP script as suggested by Google searches, but none seemed to have any effect.
Has anyone encountered similar problems before?
When I have started to run specific SQL queries, I noticed that incorrect data was being returned at certain times.
I have narrowed this down to the fact that Glovine host my website and they are 10 hours ahead of me in the UK.
So, when I run a query at say 11.00am UK time for Max temp for this day last year, the figure is correct, but if I run the same query at 8.00pm UK time, data is returned for "tomorrow last year".
Investigating this more, it is clearly to do with the time of the MySQL server, but I don't appear to be able to change this through the Glovine control panel.
I've tried several different methods of setting the timezone in my PHP script as suggested by Google searches, but none seemed to have any effect.
Has anyone encountered similar problems before?