default_scope rails alternative

187 views Asked by At

I have a database of users that uses my system once, and then I don't see them again for another 4-5 years, so I thought to myself why not "archive" all those users and only focus on the most recent ones, the ones last_sign_in_at >= DateTime.now - 10.days. I have an admin tools that uses rails_admin, and that would have been perfect to work with 5% of the DB rather than a 100%.

I did some searching and I found default_scope unfortunately I very quickly found that it was pure evil.

What would you recommend in this situation ?

thanks for your help

0

There are 0 answers