Bug in Model.count?

Hi,

I am trying to get number of events of by a certain person in a time
period.

My activerecord syntax is:
Event.count(:group => [ ‘DATE(created_at), user_id’ ])
This returns something like:
=> [[“1”, 3], [“3”, 1], [“4”, 2], [“5”, 1]]

It should have an extra date field there. Running the logged query
directly in mysql returns the proper result:

SELECT count(*) AS count_all, DATE(created_at), user_id AS
date_created_at_user_id FROM events GROUP BY DATE(created_at),
user_id

±----------±-----------------±------------------------+
| count_all | DATE(created_at) | date_created_at_user_id |
±----------±-----------------±------------------------+
| 1 | 2008-05-08 | 1 |
| 1 | 2008-06-08 | 1 |
| 1 | 2008-06-20 | 3 |
| 1 | 2008-06-24 | 1 |
| 6 | 2008-07-08 | 1 |
| 2 | 2008-07-08 | 4 |
| 1 | 2008-07-08 | 5 |
| 3 | 2008-07-09 | 1 |
| 1 | 2008-07-09 | 3 |
| 1 | 2008-07-09 | 5 |
±----------±-----------------±------------------------+


M.