Recommendation for searching with regards to timestamp & foreign key attributes

hi guys,

   I need a recommendation for searching with regards to timestamp & foreign key attributes. Sounds a bit too much but here's an example.

  Suppose we have a "blog" object. It has many attributes such as - title - content - status_id - created_at - updated_at

  There are also "status" objects which have the following statuses, "new", "edit","published","archived". That's why the "blog" object has a foreign key, "status_id".

Now, suppose I want to search for all blog objects that have been created in the past 24 hours. I would do

  new_blogs = Blog.all(:conditions => { :created_at => (Time.now - 24.hours) .. (Time.now) } )

Tested and that works just fine.

Suppose I would like to get all blog entries which are not of the status of 'published' or 'archived'. I would just make use of searchlogic in the following way:

new_blog_entries = Blog.searchlogic(:status_name_does_not_equal_all => (['published', 'archived']) ) OR new_blog_entries = Blog.status_name_does_not_equal_any(['published', 'archived'])

Question: