Hi
thanks for your reply…One more question related to this…In my
ServiceDeskTicket model i have two fields
1.updted_on
2.service_desk_status_id
I have to find out all records with time difference between
updated_on and current time > 48 hours and service_desk_status_id=6.
Could you please tell me how I can write this?
Hi
thanks for your reply…One more question related to this…In my
ServiceDeskTicket model i have two fields
1.updted_on
2.service_desk_status_id
I have to find out all records with time difference between
updated_on and current time > 48 hours and service_desk_status_id=6.
Could you please tell me how I can write this?
that’s even easier, you just need to find records where updated_on is
more than 48 hours ago. Rails even provides some helpers here:
48.hours.ago will evaluate to that time.