You most likely want $nin or $ne.
> --
> You received this message because you are subscribed to the Google Groups
> "mongodb-user" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/mongodb-user/-/kfCfrlY8z58J.
>
> To post to this group, send email to mongod...@googlegroups.com.
> To unsubscribe from this group, send email to
> mongodb-user...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/mongodb-user?hl=en.
Do an explain() and see the differences for the $ne/$nin and forcing
the index use using hint().
Are you using any other criteria other than that one in your query?
As I said, "Indexes are very useful for finding thing which match, not
which don't."
Systems like oracle simply table scan and skip indexes all together
for queries like this.