Fixed date conversion for queries so that it actually includes the time.