 <p>As far as I know, mongodb doesn't support queries against dynamic values. But you could use a javascript function:</p> <pre><code>scope :unresolved, :where =&gt; 'this.updated_at &gt;= this.checked_at' </code></pre> <p>To speed this up you could add an attribute like "is_unresolved" which will be set to true on update when this condition is matched ( and index that ).</p>