Q:

discrepancy between Time.zone.now when called by itself and in a where statement

I am trying to select items between two dates. Time.zone.now seems to respect the zone value but when called as part of Active Record, it doesn't. I am not storing my data as UTC so specifying as Time.zone.now should bring back the time of the current specified zone. How do I make this work correctly? What is the logic of the thinking? 
thx
ruby-1.9.2-p290 :009 > Time.zone.now
 => Thu, 22 Mar 2012 22:26:43 PDT -07:00 
ruby-1.9.2-p290 :010 > Event.where(:start_datetime => (Time.zone.now)..(Time.zone.now.end_of_day))
  Event Load (0.5ms)  SELECT `events`.* FROM `events` WHERE (`events`.`start_datetime` BETWEEN '2012-03-23 05:26:59' AND '2012-03-23 06:59:59')
 => [] 
ruby-1.9.2-p290 :011 > 

A:

Try the things like :
Event.where(:start_datetime => (Time.now.in_time_zone(YOUR_TIME_ZONE))..(Time.zone.now.end_of_day.in_time_zone(YOUR_TIME_ZONE))

YOUR_TIME_ZONE like "Eastern Time (US & Canada)"

