search for: time_to_sec

Displaying 3 results from an estimated 3 matches for "time_to_sec".

2006 Jul 16
4
Calculations across multiple tables
...it naive to imagine that AR''s calculations will span relations to provide a grouped result? The SQL I''m feeding to find_by_sql comes out something like this: SELECT client_id, task_id, project_id, clients.client_name, tasks.description, time_records.start_at, (SUM(TIME_TO_SEC(time_records.end_at) - time_to_sec(time_records.start_at)) / 60) AS total_client_minutes, (SUM(TIME_TO_SEC(time_records.end_at) - time_to_sec(time_records.start_at)) / 3600) AS total_client_hours FROM clients, tasks, time_records WHERE tasks.client_id = clients.id AND time_record...
2011 Dec 12
1
Creating appropriate time axis for data
Hello, I am dealing with data stored in a database as a 'time' object. I export the data from the database to a text file and utilize the 'time_to_sec()' function of the database to convert the human readable time (HH:MM:SS) to seconds so that I can use R to do analysis and create charts of the data. I do not need or use days or dates in the data, and the data range is from 07:00:00 to 18:00:00 or 25200-64800 seconds. However when I visuali...
2011 Dec 12
1
Help with charting time in seconds as HH:MM:SS on charts
Hello, I am dealing with data stored in a database as a 'time' object. I export the data from the database to a text file and utilize the 'time_to_sec()' function of the database to convert the human readable time (HH:MM:SS) to seconds so that I can use R to do analysis and create charts of the data. I do not need or use days or dates in the data, and the data range is from 07:00:00 to 18:00:00 or 25200-64800 seconds. However when I visuali...