search for: months_ago

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

2006 Oct 22
12
How to subtract months from time?
Hi there, Im reading a date out of a database and I need to subtract exactly 1 month from that date? It needs to be bullet proof so that if the date says 31 and the previous month only has 28 days it wont just subtract 1 from the month and make an illegal date. Thanks Petr -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this
2008 Mar 07
3
timestamp help
I am trying to figure out if a time stamp in my database is older then a month so that way my controller will only collect the one''s that are newer. So far I have @notes = @customer.notes.find(:all, :conditions => {:level => [''notice'', ''warning'', ''error'']}, :order => ''created_at DESC'') But I do not want it
2007 Dec 12
6
Add a month to a Date object
Howdy all, This may be the dumbest question in the world, but how can you "add one month" to a Date object? I can''t just add 30 days, because months have varying lengths. Any help would be much appreciated... Thanks! -Neal --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: