Reputation: 1955
is there a way to find documents, which property exactly match term?
E.g.: search for Test. Expected result:
{
clientName: "Test"
}
and not "Test client", "Test1" or whatever.
Currently I see only $filter possibility, though I'm not sure if it's appropriate (may be slower etc).
Regards
Upvotes: 0
Views: 614
Reputation: 8634
You can use $filter for this purpose; that is its intended usage. It uses the same kind of inverted index as full text searches without the overhead of relevance scoring, so if your query contains only filters it should actually be faster.
Upvotes: 1