This MySQL query:
SELECT unix_timestamp('2015-10-01 00:00:00')
which is at 4:00 am
however I want it to return
which is at midnight.
The problem is likely caused by a timezone issue, where a Unix Timestamp should always be in UTC time however MySQL is doing the calculation based on the time zone of the server.